(svn r13375) -Add: logging of actions that could possibly cause desyncs and crashes to simplify debugging. See readme.txt for details

This commit is contained in:
smatz
2008-06-03 18:35:58 +00:00
parent 1b7fcf0171
commit 1f55797fe3
22 changed files with 1061 additions and 31 deletions

View File

@@ -54,6 +54,7 @@
#include "strings_func.h"
#include "date_func.h"
#include "vehicle_func.h"
#include "gamelog.h"
#include "cheat_func.h"
#include "animated_tile_func.h"
#include "functions.h"
@@ -304,6 +305,7 @@ static void ShutdownGame()
UnInitializeAirports();
/* Uninitialize variables that are allocated dynamically */
GamelogReset();
_Town_pool.CleanPool();
_Industry_pool.CleanPool();
_Station_pool.CleanPool();
@@ -1257,6 +1259,13 @@ bool AfterLoadGame()
TileIndex map_size = MapSize();
Player *p;
if (CheckSavegameVersion(98)) GamelogOldver();
GamelogTestRevision();
GamelogTestMode();
if (CheckSavegameVersion(98)) GamelogGRFAddList(_grfconfig);
/* in version 2.1 of the savegame, town owner was unified. */
if (CheckSavegameVersionOldStyle(2, 1)) ConvertTownOwner();
@@ -2420,6 +2429,8 @@ bool AfterLoadGame()
}
}
if (_debug_gamelog_level > 0) GamelogPrintDebug();
return InitializeWindowsAndCaches();
}