mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-08-28 17:09:10 +00:00
(svn r998) now vehicles are serviced both when entering and when leaving depots to prevent that vehicles might need service when leaving after a long stay (ln--)
This commit is contained in:
@@ -1288,6 +1288,7 @@ static bool CheckTrainStayInDepot(Vehicle *v)
|
||||
return true;
|
||||
}
|
||||
|
||||
VehicleServiceInDepot(v);
|
||||
TrainPlayLeaveStationSound(v);
|
||||
|
||||
v->u.rail.track = 1;
|
||||
@@ -2554,9 +2555,8 @@ void TrainEnterDepot(Vehicle *v, uint tile)
|
||||
if (v->subtype != 0)
|
||||
v = GetFirstVehicleInChain(v);
|
||||
|
||||
v->date_of_last_service = _date;
|
||||
v->breakdowns_since_last_service = 0;
|
||||
v->reliability = _engines[v->engine_type].reliability;
|
||||
VehicleServiceInDepot(v);
|
||||
|
||||
InvalidateWindow(WC_VEHICLE_DETAILS, v->index);
|
||||
|
||||
v->load_unload_time_rem = 0;
|
||||
|
Reference in New Issue
Block a user