Merge remote-tracking branch 'upstream/master'

This commit is contained in:
dP
2024-03-17 01:25:55 +07:00
164 changed files with 9321 additions and 6017 deletions

View File

@@ -590,11 +590,11 @@ static void StartScripts()
/* Start the AIs. */
for (const Company *c : Company::Iterate()) {
if (Company::IsValidAiID(c->index)) AI::StartNew(c->index, false);
if (Company::IsValidAiID(c->index)) AI::StartNew(c->index);
}
/* Start the GameScript. */
Game::StartNew(false);
Game::StartNew();
ShowScriptDebugWindowIfScriptError();
}
@@ -1814,6 +1814,11 @@ bool AfterLoadGame()
if (!order->IsType(OT_GOTO_DEPOT)) continue;
order->SetDepotActionType((OrderDepotActionFlags)(order->GetDepotActionType() >> 1));
}
for (Vehicle *v : Vehicle::Iterate()) {
if (!v->current_order.IsType(OT_GOTO_DEPOT)) continue;
v->current_order.SetDepotActionType((OrderDepotActionFlags)(v->current_order.GetDepotActionType() >> 1));
}
}
/* The water class was moved/unified. */