1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-30 18:09:09 +00:00

(svn r24505) -Add: Select the GS tab if all AI tabs are unselectable in the AI debug window.

This commit is contained in:
zuu
2012-09-01 17:49:26 +00:00
parent d2b93c96e7
commit 468d232ef4

View File

@@ -1072,6 +1072,14 @@ struct AIDebugWindow : public QueryStringBaseWindow {
break;
}
}
/* If no AI is available, see if there is a game script. */
if (ai_debug_company == INVALID_COMPANY && Game::GetInstance() != NULL) {
/* Lower the widget corresponding to the game script. */
this->LowerWidget(WID_AID_SCRIPT_GAME);
ai_debug_company = OWNER_DEITY;
}
}
/* Update "Reload AI" and "AI settings" buttons */