summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2010-01-27 20:07:29 +0000
committerfrosch <frosch@openttd.org>2010-01-27 20:07:29 +0000
commitec9ac775bfe760b9b9f000cdb573796c3c8b8974 (patch)
treeebdd2a2e05c3828951a885058a50ad3aafcccbb1 /src
parent9a1dddd13794ba8ad34603c0fbae92967a697bec (diff)
downloadopenttd-ec9ac775bfe760b9b9f000cdb573796c3c8b8974.tar.xz
(svn r18929) -Fix [FS#3568]: Preserve some timetable related vehicle flags during autorenew/-replace.
Diffstat (limited to 'src')
-rw-r--r--src/vehicle_base.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/vehicle_base.h b/src/vehicle_base.h
index f3aeb3349..bea248538 100644
--- a/src/vehicle_base.h
+++ b/src/vehicle_base.h
@@ -481,6 +481,10 @@ public:
this->lateness_counter = src->lateness_counter;
this->timetable_start = src->timetable_start;
+ if (HasBit(src->vehicle_flags, VF_TIMETABLE_STARTED)) SetBit(this->vehicle_flags, VF_TIMETABLE_STARTED);
+ if (HasBit(src->vehicle_flags, VF_AUTOFILL_TIMETABLE)) SetBit(this->vehicle_flags, VF_AUTOFILL_TIMETABLE);
+ if (HasBit(src->vehicle_flags, VF_AUTOFILL_PRES_WAIT_TIME)) SetBit(this->vehicle_flags, VF_AUTOFILL_PRES_WAIT_TIME);
+
this->service_interval = src->service_interval;
}