summaryrefslogtreecommitdiff
path: root/src/newgrf_station.cpp
diff options
context:
space:
mode:
authorpeter1138 <peter1138@openttd.org>2007-04-11 21:04:03 +0000
committerpeter1138 <peter1138@openttd.org>2007-04-11 21:04:03 +0000
commit69982b1f018d120bd99338f9260760984a5ce98b (patch)
treebb3bdbca60f3320458aaf7a9f6d6d1da9cc03590 /src/newgrf_station.cpp
parentb47078d6903a9e7e9969351e86b00a1d7db6c90f (diff)
downloadopenttd-69982b1f018d120bd99338f9260760984a5ce98b.tar.xz
(svn r9601) -Codechange: Store grf file reference in station spec, not just GRF ID
Diffstat (limited to 'src/newgrf_station.cpp')
-rw-r--r--src/newgrf_station.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/newgrf_station.cpp b/src/newgrf_station.cpp
index 18b597cfa..a799e3c57 100644
--- a/src/newgrf_station.cpp
+++ b/src/newgrf_station.cpp
@@ -184,7 +184,7 @@ const StationSpec *GetCustomStationSpecByGrf(uint32 grfid, byte localidx)
for (j = 0; j < station_classes[i].stations; j++) {
const StationSpec *statspec = station_classes[i].spec[j];
if (statspec == NULL) continue;
- if (statspec->grfid == grfid && statspec->localidx == localidx) return statspec;
+ if (statspec->grffile->grfid == grfid && statspec->localidx == localidx) return statspec;
}
}
@@ -638,7 +638,7 @@ int AllocateSpecToStation(const StationSpec *statspec, Station *st, bool exec)
}
st->speclist[i].spec = statspec;
- st->speclist[i].grfid = statspec->grfid;
+ st->speclist[i].grfid = statspec->grffile->grfid;
st->speclist[i].localidx = statspec->localidx;
}