summaryrefslogtreecommitdiff
path: root/src/station_cmd.cpp
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2012-11-12 20:13:17 +0000
committerfrosch <frosch@openttd.org>2012-11-12 20:13:17 +0000
commitf3be01c26f68f88beebab4222f67ee6eae73bc1b (patch)
treedcc236acbd65932769d5f8e4ab0fe7d0fada3cfd /src/station_cmd.cpp
parent0a4fe02a47a56fd9f6a906e08f08626c9ac7afd8 (diff)
downloadopenttd-f3be01c26f68f88beebab4222f67ee6eae73bc1b.tar.xz
(svn r24714) -Fix [FS#5337]: [NewGRF] Draw default foundations if resolving of custom station foundation sprites fails.
Diffstat (limited to 'src/station_cmd.cpp')
-rw-r--r--src/station_cmd.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp
index b7725b459..cff06e580 100644
--- a/src/station_cmd.cpp
+++ b/src/station_cmd.cpp
@@ -2652,6 +2652,7 @@ static void DrawTile_Station(TileInfo *ti)
if (!HasFoundationNW(ti->tile, slope, z)) SetBit(edge_info, 0);
if (!HasFoundationNE(ti->tile, slope, z)) SetBit(edge_info, 1);
SpriteID image = GetCustomStationFoundationRelocation(statspec, st, ti->tile, tile_layout, edge_info);
+ if (image == 0) goto draw_default_foundation;
if (HasBit(statspec->flags, SSF_EXTENDED_FOUNDATIONS)) {
/* Station provides extended foundations. */