(svn r13830) -Feature: show additional NewGRF info in the Tile Info window for stations, houses and industries

This commit is contained in:
smatz
2008-07-25 22:37:34 +00:00
parent 9943ac2942
commit abea03fb89
8 changed files with 65 additions and 4 deletions

View File

@@ -43,6 +43,7 @@
#include "oldpool_func.h"
#include "animated_tile_func.h"
#include "elrail_func.h"
#include "newgrf.h"
#include "table/sprites.h"
#include "table/strings.h"
@@ -2312,6 +2313,18 @@ static void GetTileDesc_Station(TileIndex tile, TileDesc *td)
}
td->build_date = GetStationByTile(tile)->build_date;
const StationSpec *spec = GetStationSpec(tile);
if (spec != NULL) {
td->station_class = GetStationClassName(spec->sclass);
td->station_name = spec->name;
if (spec->grffile != NULL) {
const GRFConfig *gc = GetGRFConfig(spec->grffile->grfid);
td->grf = gc->name;
}
}
StringID str;
switch (GetStationType(tile)) {
default: NOT_REACHED();