From 793eba3a3a2fac64e0e4bd860d8c04d75061abd4 Mon Sep 17 00:00:00 2001 From: tron Date: Fri, 3 Jun 2005 22:43:59 +0000 Subject: (svn r2404) assert that GetTileOwner() isn't called for tiles, which don't store owner information --- tile.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'tile.h') diff --git a/tile.h b/tile.h index 7704275b5..e19a24b7f 100644 --- a/tile.h +++ b/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]; } -- cgit v1.2.3-54-g00ecf