diff options
author | yexo <yexo@openttd.org> | 2010-02-22 14:16:57 +0000 |
---|---|---|
committer | yexo <yexo@openttd.org> | 2010-02-22 14:16:57 +0000 |
commit | 7ca4c31cf558ff29b3cbe14cd348bcf649445dfc (patch) | |
tree | 7577f2eda50659c477bdfd9bfbc8068bb47261e5 /src/newgrf_airporttiles.h | |
parent | 61fe40ba73e84931d22f015783ce3c1817293b96 (diff) | |
download | openttd-7ca4c31cf558ff29b3cbe14cd348bcf649445dfc.tar.xz |
(svn r19197) -Codechange: introduce animation callbacks for airport tiles
Diffstat (limited to 'src/newgrf_airporttiles.h')
-rw-r--r-- | src/newgrf_airporttiles.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/newgrf_airporttiles.h b/src/newgrf_airporttiles.h index b5ba8787f..f295530de 100644 --- a/src/newgrf_airporttiles.h +++ b/src/newgrf_airporttiles.h @@ -17,6 +17,15 @@ #include "newgrf_commons.h" #include "airport.h" +/** Animation triggers for airport tiles */ +enum AirpAnimationTrigger { + AAT_BUILT, ///< Triggered when the airport it build (for all tiles at the same time) + AAT_TILELOOP, ///< Triggered in the periodic tile loop + AAT_STATION_NEW_CARGO, ///< Triggered when new cargo arrives at the station (for all tiles at the same time) + AAT_STATION_CARGO_TAKEN, ///< Triggered when a cargo type is completely removed from the station (for all tiles at the same time) + AAT_STATION_250_ticks, ///< Triggered every 250 ticks (for all tiles at the same time) +}; + /** * Defines the data structure of each indivudual tile of an airport. */ @@ -40,6 +49,10 @@ private: friend void AirportTileOverrideManager::SetEntitySpec(const AirportTileSpec *airpts); }; +StationGfx GetTranslatedAirportTileID(StationGfx gfx); +void AnimateAirportTile(TileIndex tile); +void AirportTileAnimationTrigger(Station *st, TileIndex tile, AirpAnimationTrigger trigger, CargoID cargo_type = CT_INVALID); +void AirportAnimationTrigger(Station *st, AirpAnimationTrigger trigger, CargoID cargo_type = CT_INVALID); bool DrawNewAirportTile(TileInfo *ti, Station *st, StationGfx gfx, const AirportTileSpec *airts); #endif /* NEWGRF_AIRPORTTILES_H */ |