summaryrefslogtreecommitdiff
path: root/train_cmd.c
diff options
context:
space:
mode:
Diffstat (limited to 'train_cmd.c')
-rw-r--r--train_cmd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/train_cmd.c b/train_cmd.c
index 256ccb6d5..50df00a59 100644
--- a/train_cmd.c
+++ b/train_cmd.c
@@ -1589,7 +1589,7 @@ static bool ProcessTrainOrder(Vehicle *v)
if (v->current_order.type == OT_GOTO_DEPOT &&
(v->current_order.flags & (OF_UNLOAD | OF_FULL_LOAD)) == (OF_UNLOAD | OF_FULL_LOAD) &&
- SERVICE_INTERVAL) {
+ !VehicleNeedsService(v)) {
v->cur_order_index++;
}
@@ -2597,7 +2597,7 @@ static void CheckIfTrainNeedsService(Vehicle *v)
if (_patches.servint_trains == 0)
return;
- if (SERVICE_INTERVAL)
+ if (!VehicleNeedsService(v))
return;
if (v->vehstatus & VS_STOPPED)