Scope resolver for handling the tiles of an airport. More...
#include <newgrf_airporttiles.h>
Public Member Functions | |
AirportTileScopeResolver (ResolverObject &ro, const AirportTileSpec *ats, TileIndex tile, Station *st) | |
Constructor of the scope resolver specific for airport tiles. | |
uint32 | GetRandomBits () const |
Get a few random bits. | |
uint32 | GetVariable (byte variable, uint32 parameter, bool *available) const |
Get a variable value. | |
Data Fields | |
struct Station * | st |
Station of the airport for which the callback is run, or NULL for build gui. | |
byte | airport_id |
Type of airport for which the callback is run. | |
TileIndex | tile |
Tile for the callback, only valid for airporttile callbacks. |
Scope resolver for handling the tiles of an airport.
Definition at line 22 of file newgrf_airporttiles.h.
AirportTileScopeResolver::AirportTileScopeResolver | ( | ResolverObject & | ro, | |
const AirportTileSpec * | ats, | |||
TileIndex | tile, | |||
Station * | st | |||
) |
Constructor of the scope resolver specific for airport tiles.
ats | Specification of the airport tiles. | |
tile | Tile for the callback, only valid for airporttile callbacks. | |
st | Station of the airport for which the callback is run, or NULL for build gui. |
Definition at line 228 of file newgrf_airporttiles.cpp.
References Station::airport, airport_id, and Airport::type.
uint32 AirportTileScopeResolver::GetRandomBits | ( | ) | const [virtual] |
Get a few random bits.
Default implementation has no random bits.
Reimplemented from ScopeResolver.
Definition at line 202 of file newgrf_airporttiles.cpp.
References GetStationTileRandomBits(), INVALID_TILE, BaseStation::random_bits, st, and tile.
uint32 AirportTileScopeResolver::GetVariable | ( | byte | variable, | |
uint32 | parameter, | |||
bool * | available | |||
) | const [virtual] |
Get a variable value.
Default implementation has no available variables.
variable | Variable to read | |
parameter | Parameter for 60+x variables | |
[out] | available | Set to false, in case the variable does not exist. |
Reimplemented from ScopeResolver.
Definition at line 161 of file newgrf_airporttiles.cpp.
References Station::airport, ClosestTownFromTile(), DEBUG, GetAirportTileIDAtOffset(), GetAnimationFrame(), GetNearbyAirportTileInformation(), GetNearbyTile(), GetRelativePosition(), GetTerrainType(), GetTownRadiusGroup(), ResolverObject::grffile, Pool< Titem, Tindex, Tgrowth_step, Tmax_size, Tpool_type, Tcache, Tzero >::PoolItem< Tpool >::index, ScopeResolver::ro, st, TileArea::tile, and tile.