Chunnel: Add error text for too many tunnels.

This commit is contained in:
Jonathan G Rennison
2017-03-04 13:06:43 +00:00
parent ab38623ea6
commit 02b33e7f64
3 changed files with 8 additions and 2 deletions

View File

@@ -2038,7 +2038,12 @@ bool AfterLoadGame()
TileIndex start_tile = t;
TileIndex end_tile = GetOtherTunnelBridgeEndOld(start_tile);
if (!Tunnel::CanAllocateItem()) return false;
if (!Tunnel::CanAllocateItem()) {
SetSaveLoadError(STR_ERROR_TUNNEL_TOO_MANY);
/* Restore the signals */
ResetSignalHandlers();
return false;
}
const Tunnel *t = new Tunnel(start_tile, end_tile, false);