mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-01-31 11:23:21 +00:00
Change: Skip reliability decay if servicing is disabled
This commit is contained in:
parent
2ff10327d7
commit
148e5b41d6
@ -1222,7 +1222,10 @@ void CheckVehicleBreakdown(Vehicle *v)
|
||||
int rel, rel_old;
|
||||
|
||||
/* decrease reliability */
|
||||
v->reliability = rel = max((rel_old = v->reliability) - v->reliability_spd_dec, 0);
|
||||
if (!_settings_game.order.no_servicing_if_no_breakdowns ||
|
||||
_settings_game.difficulty.vehicle_breakdowns != 0) {
|
||||
v->reliability = rel = max((rel_old = v->reliability) - v->reliability_spd_dec, 0);
|
||||
}
|
||||
if ((rel_old >> 8) != (rel >> 8)) SetWindowDirty(WC_VEHICLE_DETAILS, v->index);
|
||||
|
||||
if (v->breakdown_ctr != 0 || (v->vehstatus & VS_STOPPED) ||
|
||||
|
Loading…
Reference in New Issue
Block a user