mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-08-29 09:29:10 +00:00
(svn r23364) -Codechange: refactor AIConfig, moving it mostly to Scriptconfig
This commit is contained in:
@@ -1150,8 +1150,8 @@ DEF_CONSOLE_CMD(ConStartAI)
|
||||
|
||||
AIConfig *config = AIConfig::GetConfig((CompanyID)n);
|
||||
if (argc >= 2) {
|
||||
config->ChangeAI(argv[1], -1, true);
|
||||
if (!config->HasAI()) {
|
||||
config->Change(argv[1], -1, true);
|
||||
if (!config->HasScript()) {
|
||||
IConsoleWarning("Failed to load the specified AI");
|
||||
return true;
|
||||
}
|
||||
|
Reference in New Issue
Block a user