diff options
author | yexo <yexo@openttd.org> | 2010-02-22 14:17:07 +0000 |
---|---|---|
committer | yexo <yexo@openttd.org> | 2010-02-22 14:17:07 +0000 |
commit | 698737f485cfbdd1605faecd50395bb67f7dac75 (patch) | |
tree | b79303520896365e70a9aa3224a5f1c6a14b5aba /src/newgrf_airporttiles.cpp | |
parent | 7ca4c31cf558ff29b3cbe14cd348bcf649445dfc (diff) | |
download | openttd-698737f485cfbdd1605faecd50395bb67f7dac75.tar.xz |
(svn r19198) -Codechange: store the size of stations in savegames
Diffstat (limited to 'src/newgrf_airporttiles.cpp')
-rw-r--r-- | src/newgrf_airporttiles.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/newgrf_airporttiles.cpp b/src/newgrf_airporttiles.cpp index b190c043f..05e7951a4 100644 --- a/src/newgrf_airporttiles.cpp +++ b/src/newgrf_airporttiles.cpp @@ -180,7 +180,7 @@ static uint32 AirportTileGetVariable(const ResolverObject *object, byte variable case 0x42: return GetTownRadiusGroup(ClosestTownFromTile(tile, UINT_MAX), tile); /* Position relative to most northern airport tile. */ - case 0x43: return GetRelativePosition(tile, st->airport_tile); + case 0x43: return GetRelativePosition(tile, st->airport.tile); /* Animation frame of tile */ case 0x44: return GetStationAnimationFrame(tile); @@ -390,13 +390,11 @@ void AirportTileAnimationTrigger(Station *st, TileIndex tile, AirpAnimationTrigg void AirportAnimationTrigger(Station *st, AirpAnimationTrigger trigger, CargoID cargo_type) { - if (st->airport_tile == INVALID_TILE) return; + if (st->airport.tile == INVALID_TILE) return; const AirportSpec *as = st->GetAirportSpec(); - int w = as->size_x; - int h = as->size_y; - TILE_LOOP(tile, w, h, st->airport_tile) { + TILE_AREA_LOOP(tile, st->airport) { if (st->TileBelongsToAirport(tile)) AirportTileAnimationTrigger(st, tile, trigger, cargo_type); } } |