diff options
author | rubidium <rubidium@openttd.org> | 2011-08-21 12:52:24 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2011-08-21 12:52:24 +0000 |
commit | 5ea6064fab18eb7281f2d4adc3ba4d961b9c3f7f (patch) | |
tree | d5717a8d1894ba449868b452cb0a9fe80fbb81ba /src | |
parent | d1657fae80732d69a3c7a50b4f06292400d1d759 (diff) | |
download | openttd-5ea6064fab18eb7281f2d4adc3ba4d961b9c3f7f.tar.xz |
(svn r22795) -Codechange: load the intro game the first time without NewGRFs
Diffstat (limited to 'src')
-rw-r--r-- | src/openttd.cpp | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/openttd.cpp b/src/openttd.cpp index 6007bb4aa..e078c7da0 100644 --- a/src/openttd.cpp +++ b/src/openttd.cpp @@ -265,11 +265,15 @@ static void ShutdownGame() FioCloseAll(); } -static void LoadIntroGame() +/** + * Load the introduction game. + * @param load_newgrfs Whether to load the NewGRFs or not. + */ +static void LoadIntroGame(bool load_newgrfs = true) { _game_mode = GM_MENU; - ResetGRFConfig(false); + if (load_newgrfs) ResetGRFConfig(false); /* Setup main window */ ResetWindowSystem(); @@ -710,6 +714,8 @@ int ttd_main(int argc, char *argv[]) GenerateWorld(GWM_EMPTY, 64, 64); // Make the viewport initialization happy WaitTillGeneratedWorld(); + LoadIntroGame(false); + CheckForMissingGlyphsInLoadedLanguagePack(); ScanNewGRFFiles(new AfterNewGRFScan(network ? network_conn : NULL, join_server_password, join_company_password)); @@ -1227,7 +1233,7 @@ void GameLoop() } /* switch game mode? */ - if (_switch_mode != SM_NONE) { + if (_switch_mode != SM_NONE && !HasModalProgress()) { SwitchToMode(_switch_mode); _switch_mode = SM_NONE; } |