Mercurial > hg > openttd
changeset 7062:1a0ddc74cd95 draft
(svn r10327) -Fix (r10236) [FS#934]: Vehicles wait at stations when they arrive early even
if they haven't been timetabled to wait, so make sure the lateness counter gets
updated as well.
author | maedhros <maedhros@openttd.org> |
---|---|
date | Mon, 25 Jun 2007 17:17:40 +0000 (2007-06-25) |
parents | e05c1eed99b8 |
children | ec920a4e40bd |
files | src/timetable_cmd.cpp |
diffstat | 1 files changed, 4 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/timetable_cmd.cpp +++ b/src/timetable_cmd.cpp @@ -95,7 +95,10 @@ v->current_order_time = 0; - if (!_patches.timetabling || timetabled == 0) return; + /* Vehicles will wait at stations if they arrive early even if they are not + * timetabled to wait there, so make sure the lateness counter is updated + * when this happens. */ + if (!_patches.timetabling || (timetabled == 0 && (travelling || v->lateness_counter >= 0))) return; v->lateness_counter -= (timetabled - time_taken);