diff options
author | frosch <frosch@openttd.org> | 2010-08-09 07:10:42 +0000 |
---|---|---|
committer | frosch <frosch@openttd.org> | 2010-08-09 07:10:42 +0000 |
commit | 48c5091a7c39739e48d06ec365af4f7c713dd25a (patch) | |
tree | fae43b0772a1cf96b2684adcedc42f8f4d19e34e /src/newgrf_commons.h | |
parent | 67c21f7e01b7f83c77e934c4fe0771324853d2ab (diff) | |
download | openttd-48c5091a7c39739e48d06ec365af4f7c713dd25a.tar.xz |
(svn r20420) -Codechange: Add TileContext enum instead of using a bool.
Diffstat (limited to 'src/newgrf_commons.h')
-rw-r--r-- | src/newgrf_commons.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/newgrf_commons.h b/src/newgrf_commons.h index 0b7ee3d85..9ff994a2e 100644 --- a/src/newgrf_commons.h +++ b/src/newgrf_commons.h @@ -17,6 +17,12 @@ #include "tile_cmd.h" +/** Contextx for tile accesses */ +enum TileContext { + TC_NORMAL, ///< Nothing special. + TC_UPPER_HALFTILE, ///< Querying information about the upper part of a tile with halftile foundation. +}; + /** * Maps an entity id stored on the map to a GRF file. * Entities are objects used ingame (houses, industries, industry tiles) for @@ -124,7 +130,7 @@ extern IndustryTileOverrideManager _industile_mngr; extern AirportOverrideManager _airport_mngr; extern AirportTileOverrideManager _airporttile_mngr; -uint32 GetTerrainType(TileIndex tile, bool upper_halftile = false); +uint32 GetTerrainType(TileIndex tile, TileContext context = TC_NORMAL); TileIndex GetNearbyTile(byte parameter, TileIndex tile); uint32 GetNearbyTileInformation(TileIndex tile); |