summaryrefslogtreecommitdiff
path: root/src/town_cmd.cpp
diff options
context:
space:
mode:
authoryexo <yexo@openttd.org>2010-10-28 11:10:12 +0000
committeryexo <yexo@openttd.org>2010-10-28 11:10:12 +0000
commit9a07ebc382dcf211dcc6c9673269f578386447a9 (patch)
tree0bd46ae3f76475e7336cac7a2f03d1c1eb449cc9 /src/town_cmd.cpp
parent05407c9b74b483ba5f7e533d6263d8a6c8e104a5 (diff)
downloadopenttd-9a07ebc382dcf211dcc6c9673269f578386447a9.tar.xz
(svn r21052) -Fix (r20435): house/airporttile/industrytile newgrfs that defined tiles that relied on the substitute being drawn were broken
Diffstat (limited to 'src/town_cmd.cpp')
-rw-r--r--src/town_cmd.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/town_cmd.cpp b/src/town_cmd.cpp
index d2a983ddc..e08cbb158 100644
--- a/src/town_cmd.cpp
+++ b/src/town_cmd.cpp
@@ -207,7 +207,7 @@ static void DrawTile_Town(TileInfo *ti)
/* Houses don't necessarily need new graphics. If they don't have a
* spritegroup associated with them, then the sprite for the substitute
* house id is drawn instead. */
- if (HouseSpec::Get(house_id)->grf_prop.spritegroup != NULL) {
+ if (HouseSpec::Get(house_id)->grf_prop.spritegroup[0] != NULL) {
DrawNewHouseTile(ti, house_id);
return;
} else {
@@ -264,7 +264,7 @@ static Foundation GetFoundation_Town(TileIndex tile, Slope tileh)
*/
if (hid >= NEW_HOUSE_OFFSET) {
const HouseSpec *hs = HouseSpec::Get(hid);
- if (hs->grf_prop.spritegroup != NULL && HasBit(hs->callback_mask, CBM_HOUSE_DRAW_FOUNDATIONS)) {
+ if (hs->grf_prop.spritegroup[0] != NULL && HasBit(hs->callback_mask, CBM_HOUSE_DRAW_FOUNDATIONS)) {
uint32 callback_res = GetHouseCallback(CBID_HOUSE_DRAW_FOUNDATIONS, 0, 0, hid, Town::GetByTile(tile), tile);
if (callback_res == 0) return FOUNDATION_NONE;
}