diff options
author | rubidium <rubidium@openttd.org> | 2010-05-12 19:21:00 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2010-05-12 19:21:00 +0000 |
commit | 93ff7d78e17ca68684065924942e40a355b58670 (patch) | |
tree | 2b363403e4e6b54d778ab55d78c2f15c27df8141 /src/saveload/afterload.cpp | |
parent | 863ff6522b671ce69a1265fe246149b25e83a847 (diff) | |
download | openttd-93ff7d78e17ca68684065924942e40a355b58670.tar.xz |
(svn r19799) -Change: give depots an unique name in the same manner buoys and waypoints are named
Diffstat (limited to 'src/saveload/afterload.cpp')
-rw-r--r-- | src/saveload/afterload.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/saveload/afterload.cpp b/src/saveload/afterload.cpp index 4ff915742..9ab519242 100644 --- a/src/saveload/afterload.cpp +++ b/src/saveload/afterload.cpp @@ -2106,6 +2106,14 @@ bool AfterLoadGame() /* Reset tropic zone for VOID tiles, they shall not have any. */ if (IsTileType(t, MP_VOID)) SetTropicZone(t, TROPICZONE_NORMAL); } + + /* We need to properly number/name the depots. + * The first step is making sure none of the depots uses the + * 'default' names, after that we can assign the names. */ + Depot *d; + FOR_ALL_DEPOTS(d) d->town_cn = UINT16_MAX; + + FOR_ALL_DEPOTS(d) MakeDefaultName(d); } /* Road stops is 'only' updating some caches */ |