summaryrefslogtreecommitdiff
path: root/src/saveload
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2010-06-13 14:07:49 +0000
committerfrosch <frosch@openttd.org>2010-06-13 14:07:49 +0000
commit641fc68aa80fc24fa277ae3dc62eec2969bdd26b (patch)
tree1e980b24f7e52733370eee2a40ee009e3b8ded97 /src/saveload
parent67bec51f27d47949010ae4eaf777a622619893c8 (diff)
downloadopenttd-641fc68aa80fc24fa277ae3dc62eec2969bdd26b.tar.xz
(svn r19971) -Codechange: Make IsGoodGRFConfigList() operate on any given GRFConfig and move the GameLog operations directly to AfterLoad().
Diffstat (limited to 'src/saveload')
-rw-r--r--src/saveload/afterload.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/saveload/afterload.cpp b/src/saveload/afterload.cpp
index 5b9553be3..c616ce6e7 100644
--- a/src/saveload/afterload.cpp
+++ b/src/saveload/afterload.cpp
@@ -546,7 +546,15 @@ bool AfterLoadGame()
if (_settings_game.vehicle.road_side) _settings_game.vehicle.road_side = 1;
/* Check if all NewGRFs are present, we are very strict in MP mode */
- GRFListCompatibility gcf_res = IsGoodGRFConfigList();
+ GRFListCompatibility gcf_res = IsGoodGRFConfigList(_grfconfig);
+ for (GRFConfig *c = _grfconfig; c != NULL; c = c->next) {
+ if (c->status == GCS_NOT_FOUND) {
+ GamelogGRFRemove(c->ident.grfid);
+ } else if (HasBit(c->flags, GCF_COMPATIBLE)) {
+ GamelogGRFCompatible(&c->ident);
+ }
+ }
+
if (_networking && gcf_res != GLC_ALL_GOOD) {
SetSaveLoadError(STR_NETWORK_ERROR_CLIENT_NEWGRF_MISMATCH);
/* Restore the signals */