diff options
author | frosch <frosch@openttd.org> | 2010-06-13 14:07:49 +0000 |
---|---|---|
committer | frosch <frosch@openttd.org> | 2010-06-13 14:07:49 +0000 |
commit | 641fc68aa80fc24fa277ae3dc62eec2969bdd26b (patch) | |
tree | 1e980b24f7e52733370eee2a40ee009e3b8ded97 /src/saveload | |
parent | 67bec51f27d47949010ae4eaf777a622619893c8 (diff) | |
download | openttd-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.cpp | 10 |
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 */ |