summaryrefslogtreecommitdiff
path: root/industry_map.h
diff options
context:
space:
mode:
authortron <tron@openttd.org>2006-03-24 13:46:45 +0000
committertron <tron@openttd.org>2006-03-24 13:46:45 +0000
commitd1bd1a7035569f1adc87e0a30ab94b4ce97b13b8 (patch)
treefb604546b64177ffd43390979150de41b4f03556 /industry_map.h
parent662885ecd109f24688858c4b777b8292bece2d88 (diff)
downloadopenttd-d1bd1a7035569f1adc87e0a30ab94b4ce97b13b8.tar.xz
(svn r4087) Add IsIndustryCompleted() to check if a industry tile is fully built
Diffstat (limited to 'industry_map.h')
-rw-r--r--industry_map.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/industry_map.h b/industry_map.h
index 63c289503..d3646cd95 100644
--- a/industry_map.h
+++ b/industry_map.h
@@ -16,6 +16,12 @@ static inline Industry* GetIndustryByTile(TileIndex t)
}
+static inline bool IsIndustryCompleted(TileIndex tile)
+{
+ return HASBIT(_m[tile].m1, 7);
+}
+
+
static inline void MakeIndustry(TileIndex t, uint index, uint gfx)
{
SetTileType(t, MP_INDUSTRY);