mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-02-02 12:24:15 +00:00
(svn r9839) -Fix: vehicles in old savegames could leave the station because the changed loading algorithm thought it was already finished.
This commit is contained in:
parent
72662e15f9
commit
54de7d90f6
@ -1934,6 +1934,10 @@ bool AfterLoadGame()
|
|||||||
!(v->vehstatus & (VS_STOPPED | VS_CRASHED)) && // not stopped or crashed
|
!(v->vehstatus & (VS_STOPPED | VS_CRASHED)) && // not stopped or crashed
|
||||||
v->current_order.type == OT_LOADING) { // loading
|
v->current_order.type == OT_LOADING) { // loading
|
||||||
GetStation(v->last_station_visited)->loading_vehicles.push_back(v);
|
GetStation(v->last_station_visited)->loading_vehicles.push_back(v);
|
||||||
|
|
||||||
|
/* The loading finished flag is *only* set when actually completely
|
||||||
|
* finished. Because the vehicle is loading, it is not finished. */
|
||||||
|
CLRBIT(v->vehicle_flags, VF_LOADING_FINISHED);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user