summaryrefslogtreecommitdiff
path: root/src/saveload
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-12-02 16:20:44 +0000
committerrubidium <rubidium@openttd.org>2009-12-02 16:20:44 +0000
commit81062163a25497e9d83fd354b53234d1796f675d (patch)
tree207947eb4a906654b373c62ba6b6fca2fbe96727 /src/saveload
parent1c65150d6d30e460d1615c907e9c403d45a518ed (diff)
downloadopenttd-81062163a25497e9d83fd354b53234d1796f675d.tar.xz
(svn r18377) -Codechange: add 'cache' of the tile area of truck and bus stops.
Diffstat (limited to 'src/saveload')
-rw-r--r--src/saveload/station_sl.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/saveload/station_sl.cpp b/src/saveload/station_sl.cpp
index 1e0f6d887..6c52e7cf6 100644
--- a/src/saveload/station_sl.cpp
+++ b/src/saveload/station_sl.cpp
@@ -98,6 +98,12 @@ void AfterLoadStations()
st->speclist[i].spec = GetCustomStationSpecByGrf(st->speclist[i].grfid, st->speclist[i].localidx, NULL);
}
+ if (Station::IsExpected(st)) {
+ Station *sta = Station::From(st);
+ for (const RoadStop *rs = sta->bus_stops; rs != NULL; rs = rs->next) sta->bus_station.Add(rs->xy);
+ for (const RoadStop *rs = sta->truck_stops; rs != NULL; rs = rs->next) sta->truck_station.Add(rs->xy);
+ }
+
StationUpdateAnimTriggers(st);
}
}