forked from mirror/OpenTTD
(svn r2404) assert that GetTileOwner() isn't called for tiles, which don't store owner information
This commit is contained in:
4
tile.h
4
tile.h
@@ -81,6 +81,10 @@ static inline bool IsTileType(TileIndex tile, TileType type)
|
||||
static inline Owner GetTileOwner(TileIndex tile)
|
||||
{
|
||||
assert(tile < MapSize());
|
||||
assert(!IsTileType(tile, MP_HOUSE));
|
||||
assert(!IsTileType(tile, MP_VOID));
|
||||
assert(!IsTileType(tile, MP_INDUSTRY));
|
||||
|
||||
return _map_owner[tile];
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user