* Start the scripts. */
| 538 | * Start the scripts. |
| 539 | */ |
| 540 | static void StartScripts() |
| 541 | { |
| 542 | /* Script debug window requires AIs to be started before trying to start GameScript. */ |
| 543 | |
| 544 | /* Start the AIs. */ |
| 545 | for (const Company *c : Company::Iterate()) { |
| 546 | if (Company::IsValidAiID(c->index)) AI::StartNew(c->index); |
| 547 | } |
| 548 | |
| 549 | /* Start the GameScript. */ |
| 550 | Game::StartNew(); |
| 551 | |
| 552 | ShowScriptDebugWindowIfScriptError(); |
| 553 | } |
| 554 | |
| 555 | /** |
| 556 | * Perform a (large) amount of savegame conversion *magic* in order to |
no test coverage detected