mirror of https://github.com/OpenTTD/OpenTTD
Codechange: Re-order load update for SLV_139
It is no longer required to be performed before the first phase of vehicle updatespull/13005/head
parent
f19829d029
commit
8ed983b3cd
|
@ -817,17 +817,6 @@ bool AfterLoadGame()
|
|||
* filled; and that could eventually lead to desyncs. */
|
||||
CargoPacket::AfterLoad();
|
||||
|
||||
/* Oilrig was moved from id 15 to 9. We have to do this conversion
|
||||
* here as AfterLoadVehicles can check it indirectly via the newgrf
|
||||
* code. */
|
||||
if (IsSavegameVersionBefore(SLV_139)) {
|
||||
for (Station *st : Station::Iterate()) {
|
||||
if (st->airport.tile != INVALID_TILE && st->airport.type == 15) {
|
||||
st->airport.type = AT_OILRIG;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Update all vehicles: Phase 1 */
|
||||
AfterLoadVehiclesPhase1(true);
|
||||
|
||||
|
@ -2393,6 +2382,15 @@ bool AfterLoadGame()
|
|||
}
|
||||
}
|
||||
|
||||
/* Oilrig was moved from id 15 to 9. */
|
||||
if (IsSavegameVersionBefore(SLV_139)) {
|
||||
for (Station *st : Station::Iterate()) {
|
||||
if (st->airport.tile != INVALID_TILE && st->airport.type == 15) {
|
||||
st->airport.type = AT_OILRIG;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (IsSavegameVersionBefore(SLV_140)) {
|
||||
for (Station *st : Station::Iterate()) {
|
||||
if (st->airport.tile != INVALID_TILE) {
|
||||
|
|
Loading…
Reference in New Issue