Codechange: use std::vector/std::span for DrawTileSprites over malloc-ed table
This commit is contained in:
@@ -3084,7 +3084,7 @@ bool SplitGroundSpriteForOverlay(const TileInfo *ti, SpriteID *ground, RailTrack
|
||||
static void DrawTile_Station(TileInfo *ti)
|
||||
{
|
||||
const NewGRFSpriteLayout *layout = nullptr;
|
||||
DrawTileSprites tmp_rail_layout;
|
||||
DrawTileSpriteSpan tmp_rail_layout;
|
||||
const DrawTileSprites *t = nullptr;
|
||||
int32_t total_offset;
|
||||
const RailTypeInfo *rti = nullptr;
|
||||
@@ -3167,7 +3167,7 @@ static void DrawTile_Station(TileInfo *ti)
|
||||
palette = PALETTE_TO_GREY;
|
||||
}
|
||||
|
||||
if (layout == nullptr && (t == nullptr || t->seq == nullptr)) t = GetStationTileLayout(GetStationType(ti->tile), gfx);
|
||||
if (layout == nullptr && (t == nullptr || t->GetSequence().empty())) t = GetStationTileLayout(GetStationType(ti->tile), gfx);
|
||||
|
||||
/* don't show foundation for docks */
|
||||
if (ti->tileh != SLOPE_FLAT && !IsDock(ti->tile)) {
|
||||
|
||||
Reference in New Issue
Block a user