mirror of https://github.com/OpenTTD/OpenTTD.git
(svn r19388) -Fix [FS#3666]: [NoAI] When reloading a savegame, an AI failing to compile could trigger (trying) to read the not yet loaded information of another AI via the AI Debug window and its "open with the most recently used AI" feature
This commit is contained in:
parent
8b041e8027
commit
e3fb793a8a
|
@ -1016,3 +1016,11 @@ void ShowAIDebugWindow(CompanyID show_company)
|
|||
ShowErrorMessage(STR_ERROR_AI_DEBUG_SERVER_ONLY, INVALID_STRING_ID, WL_INFO);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Reset the AI windows to their initial state.
|
||||
*/
|
||||
void InitializeAIGui()
|
||||
{
|
||||
AIDebugWindow::ai_debug_company = INVALID_COMPANY;
|
||||
}
|
||||
|
|
|
@ -41,6 +41,7 @@ void InitializeRailGui();
|
|||
void InitializeRoadGui();
|
||||
void InitializeAirportGui();
|
||||
void InitializeDockGui();
|
||||
void InitializeAIGui();
|
||||
void InitializeIndustries();
|
||||
void InitializeTowns();
|
||||
void InitializeSubsidies();
|
||||
|
@ -92,6 +93,7 @@ void InitializeGame(uint size_x, uint size_y, bool reset_date, bool reset_settin
|
|||
InitializeRoadGui();
|
||||
InitializeAirportGui();
|
||||
InitializeDockGui();
|
||||
InitializeAIGui();
|
||||
InitializeTowns();
|
||||
InitializeSubsidies();
|
||||
InitializeTrees();
|
||||
|
|
Loading…
Reference in New Issue