summaryrefslogtreecommitdiff
path: root/src/saveload
diff options
context:
space:
mode:
Diffstat (limited to 'src/saveload')
-rw-r--r--src/saveload/afterload.cpp13
1 files changed, 2 insertions, 11 deletions
diff --git a/src/saveload/afterload.cpp b/src/saveload/afterload.cpp
index a26ef0e6b..7879af4e7 100644
--- a/src/saveload/afterload.cpp
+++ b/src/saveload/afterload.cpp
@@ -1708,18 +1708,9 @@ bool AfterLoadGame()
/* Reserve all tracks trains are currently on. */
if (CheckSavegameVersion(101)) {
- Train *t;
+ const Train *t;
FOR_ALL_TRAINS(t) {
- switch (t->track) {
- case TRACK_BIT_WORMHOLE:
- TryReserveRailTrack(t->tile, DiagDirToDiagTrack(GetTunnelBridgeDirection(t->tile)));
- break;
- case TRACK_BIT_DEPOT:
- break;
- default:
- TryReserveRailTrack(t->tile, TrackBitsToTrack(t->track));
- break;
- }
+ if (t->First() == t) t->ReserveTrackUnderConsist();
}
}