diff options
author | yexo <yexo@openttd.org> | 2010-02-22 14:17:17 +0000 |
---|---|---|
committer | yexo <yexo@openttd.org> | 2010-02-22 14:17:17 +0000 |
commit | 06dc421f2ab025aa248a372d48c5701d7a9e2ff9 (patch) | |
tree | 7542a38804ee09694b5ea606a7a74a861c1375b5 /src/station_cmd.cpp | |
parent | 698737f485cfbdd1605faecd50395bb67f7dac75 (diff) | |
download | openttd-06dc421f2ab025aa248a372d48c5701d7a9e2ff9.tar.xz |
(svn r19199) -Codechange: add a 'name'-property to airport tiles
Diffstat (limited to 'src/station_cmd.cpp')
-rw-r--r-- | src/station_cmd.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp index d3e033ccf..ad0eaa4a6 100644 --- a/src/station_cmd.cpp +++ b/src/station_cmd.cpp @@ -2643,6 +2643,16 @@ static void GetTileDesc_Station(TileIndex tile, TileDesc *td) } } + if (IsAirport(tile)) { + const AirportTileSpec *ats = AirportTileSpec::Get(GetAirportGfx(tile)); + td->airport_tile_name = ats->name; + + if (ats->grf_prop.grffile != NULL) { + const GRFConfig *gc = GetGRFConfig(ats->grf_prop.grffile->grfid); + td->grf = gc->name; + } + } + StringID str; switch (GetStationType(tile)) { default: NOT_REACHED(); |