summaryrefslogtreecommitdiff
path: root/src/town_cmd.cpp
diff options
context:
space:
mode:
authorsmatz <smatz@openttd.org>2008-07-25 22:37:34 +0000
committersmatz <smatz@openttd.org>2008-07-25 22:37:34 +0000
commitabea03fb896c14375491f94cfecc9c909c39d5d7 (patch)
tree1a6093e36d4bb9122b5adce8c2e74ff3fc512aa2 /src/town_cmd.cpp
parent9943ac29420d324ea580c3d869cb906e8cdc0ef8 (diff)
downloadopenttd-abea03fb896c14375491f94cfecc9c909c39d5d7.tar.xz
(svn r13830) -Feature: show additional NewGRF info in the Tile Info window for stations, houses and industries
Diffstat (limited to 'src/town_cmd.cpp')
-rw-r--r--src/town_cmd.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/town_cmd.cpp b/src/town_cmd.cpp
index 00236df3c..4d5917562 100644
--- a/src/town_cmd.cpp
+++ b/src/town_cmd.cpp
@@ -616,12 +616,19 @@ static void GetAcceptedCargo_Town(TileIndex tile, AcceptedCargo ac)
static void GetTileDesc_Town(TileIndex tile, TileDesc *td)
{
- td->str = GetHouseSpecs(GetHouseType(tile))->building_name;
+ const HouseSpec *hs = GetHouseSpecs(GetHouseType(tile));
+
+ td->str = hs->building_name;
if (!IsHouseCompleted(tile)) {
SetDParamX(td->dparam, 0, td->str);
td->str = STR_2058_UNDER_CONSTRUCTION;
}
+ if (hs->grffile != NULL) {
+ const GRFConfig *gc = GetGRFConfig(hs->grffile->grfid);
+ td->grf = gc->name;
+ }
+
td->owner[0] = OWNER_TOWN;
}