(svn r19933) -Fix [FS#3804]: Keep _current_company and _local_company in sync during GUI operation.

This commit is contained in:
frosch
2010-06-05 13:32:42 +00:00
parent e852bf154f
commit 9e53f1e004
7 changed files with 54 additions and 39 deletions

View File

@@ -809,7 +809,6 @@ static void MakeNewGameDone()
IConsoleCmdExec("exec scripts/game_start.scr 0");
SetLocalCompany(COMPANY_FIRST);
_current_company = _local_company;
InitializeRailGUI();
@@ -895,7 +894,6 @@ static void StartScenario()
StartupDisasters();
SetLocalCompany(COMPANY_FIRST);
_current_company = _local_company;
Company *c = Company::Get(COMPANY_FIRST);
c->settings = _settings_client.company;
@@ -1231,6 +1229,8 @@ void StateGameLoop()
NewsLoop();
cur_company.Restore();
}
assert(_current_company == _local_company);
}
/** Create an autosave. The default name is "autosave#.sav". However with