diff options
author | tron <tron@openttd.org> | 2006-03-24 13:31:17 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2006-03-24 13:31:17 +0000 |
commit | 662885ecd109f24688858c4b777b8292bece2d88 (patch) | |
tree | 4c2227ca2e8c592799085fda417f02d20fb6aa74 /industry_map.h | |
parent | c699d0e791c31170557351d4d46637b3c253dc90 (diff) | |
download | openttd-662885ecd109f24688858c4b777b8292bece2d88.tar.xz |
(svn r4086) Add MakeIndustry()
Diffstat (limited to 'industry_map.h')
-rw-r--r-- | industry_map.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/industry_map.h b/industry_map.h index c3a8d0b1c..63c289503 100644 --- a/industry_map.h +++ b/industry_map.h @@ -14,3 +14,14 @@ static inline Industry* GetIndustryByTile(TileIndex t) { return GetIndustry(GetIndustryIndex(t)); } + + +static inline void MakeIndustry(TileIndex t, uint index, uint gfx) +{ + SetTileType(t, MP_INDUSTRY); + _m[t].m1 = 0; + _m[t].m2 = index; + _m[t].m3 = 0; + _m[t].m4 = 0; + _m[t].m5 = gfx; +} |