summaryrefslogtreecommitdiff
path: root/src/saveload
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-05-22 22:55:41 +0000
committerrubidium <rubidium@openttd.org>2009-05-22 22:55:41 +0000
commitda5661a0c8870c532c393ec3d330c3fbb44eb8ac (patch)
tree93b9332d7e83e012a46777e2baf91bf323ea9fe9 /src/saveload
parentc4b627af422075ce4a0e1026c52f871dd3f146c0 (diff)
downloadopenttd-da5661a0c8870c532c393ec3d330c3fbb44eb8ac.tar.xz
(svn r16393) -Codechange: move VehicleRail to Train.
Diffstat (limited to 'src/saveload')
-rw-r--r--src/saveload/vehicle_sl.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/saveload/vehicle_sl.cpp b/src/saveload/vehicle_sl.cpp
index cdf585eca..5de480a56 100644
--- a/src/saveload/vehicle_sl.cpp
+++ b/src/saveload/vehicle_sl.cpp
@@ -252,7 +252,7 @@ void AfterLoadVehicles(bool part_of_load)
if (part_of_load) v->fill_percent_te_id = INVALID_TE_ID;
v->first = NULL;
- if (v->type == VEH_TRAIN) v->u.rail.first_engine = INVALID_ENGINE;
+ if (v->type == VEH_TRAIN) ((Train *)v)->tcache.first_engine = INVALID_ENGINE;
if (v->type == VEH_ROAD) ((RoadVehicle *)v)->first_engine = INVALID_ENGINE;
v->cargo.InvalidateCache();
@@ -318,7 +318,7 @@ void AfterLoadVehicles(bool part_of_load)
assert(v->first != NULL);
if (v->type == VEH_TRAIN && (IsFrontEngine(v) || IsFreeWagon(v))) {
- if (IsFrontEngine(v)) ((Train *)v)->u.rail.last_speed = v->cur_speed; // update displayed train speed
+ if (IsFrontEngine(v)) ((Train *)v)->tcache.last_speed = v->cur_speed; // update displayed train speed
TrainConsistChanged((Train *)v, false);
} else if (v->type == VEH_ROAD && IsRoadVehFront(v)) {
RoadVehUpdateCache((RoadVehicle *)v);