summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Nelson <peter1138@openttd.org>2019-02-16 00:15:21 +0000
committerPeterN <peter@fuzzle.org>2019-03-09 18:16:33 +0000
commit943c58e468d70a2cf77c11d346c8229030083d15 (patch)
treeda89c43689c3add69d1e06960a77f5ba93737dc8
parent8b1b3fd0f91fd30d09d3acaa65bd9a7d23d966cc (diff)
downloadopenttd-943c58e468d70a2cf77c11d346c8229030083d15.tar.xz
Fix: Show industry name in Land Area Information window for oil-rig type stations instead of just 'Oil Rig'
-rw-r--r--src/station_cmd.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp
index 2006243cb..cb588ef80 100644
--- a/src/station_cmd.cpp
+++ b/src/station_cmd.cpp
@@ -3054,7 +3054,14 @@ static void GetTileDesc_Station(TileIndex tile, TileDesc *td)
break;
case STATION_TRUCK: str = STR_LAI_STATION_DESCRIPTION_TRUCK_LOADING_AREA; break;
case STATION_BUS: str = STR_LAI_STATION_DESCRIPTION_BUS_STATION; break;
- case STATION_OILRIG: str = STR_INDUSTRY_NAME_OIL_RIG; break;
+ case STATION_OILRIG: {
+ const Industry *i = Station::GetByTile(tile)->industry;
+ const IndustrySpec *is = GetIndustrySpec(i->type);
+ td->owner[0] = i->owner;
+ str = is->name;
+ if (is->grf_prop.grffile != NULL) td->grf = GetGRFConfig(is->grf_prop.grffile->grfid)->GetName();
+ break;
+ }
case STATION_DOCK: str = STR_LAI_STATION_DESCRIPTION_SHIP_DOCK; break;
case STATION_BUOY: str = STR_LAI_STATION_DESCRIPTION_BUOY; break;
case STATION_WAYPOINT: str = STR_LAI_STATION_DESCRIPTION_WAYPOINT; break;