Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
(svn r26574) -Fix [FS#6006]: Don't reset current order wait time if i…
…t's timetabled.
  • Loading branch information
ulfhermann committed May 11, 2014
1 parent 1a47fb0 commit 726e1b6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/timetable_cmd.cpp
Expand Up @@ -395,7 +395,8 @@ void UpdateVehicleTimetable(Vehicle *v, bool travelling)
if (!HasBit(v->vehicle_flags, VF_TIMETABLE_STARTED)) return;

bool autofilling = HasBit(v->vehicle_flags, VF_AUTOFILL_TIMETABLE);
if (travelling && !HasBit(v->vehicle_flags, VF_AUTOFILL_PRES_WAIT_TIME)) {
if (travelling && (!v->current_order.IsWaitTimetabled() ||
(autofilling && !HasBit(v->vehicle_flags, VF_AUTOFILL_PRES_WAIT_TIME)))) {
/* Need to clear that now as otherwise we are not able to reduce the wait time */
v->current_order.SetWaitTime(0);
}
Expand Down

0 comments on commit 726e1b6

Please sign in to comment.