From 99158287fd34351e811acef1cb5e1fbdbe059439 Mon Sep 17 00:00:00 2001 From: belugas Date: Fri, 24 Aug 2007 00:23:35 +0000 Subject: (svn r10972) -Codechange: Implement the counterpart(GetTranslatedIndustryTileID) of getindustileid of TTDPatch. This allows to ensure that the ID of a tile (taken out of the map or not) is still a valid one regarding the possible override it may have been flagged to. It is not the strict same thing, but is what we need regarding the slightly different approach we took for newindustries. --- src/industry_map.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/industry_map.h') diff --git a/src/industry_map.h b/src/industry_map.h index 91ea96972..18e72eb33 100644 --- a/src/industry_map.h +++ b/src/industry_map.h @@ -132,7 +132,7 @@ static inline void SetIndustryConstructionStage(TileIndex tile, byte value) static inline IndustryGfx GetIndustryGfx(TileIndex t) { assert(IsTileType(t, MP_INDUSTRY)); - return _m[t].m5; + return GetTranslatedIndustryTileID(_m[t].m5 | (GB(_m[t].m6, 2, 1) << 8)); } /** -- cgit v1.2.3-54-g00ecf