summaryrefslogtreecommitdiff
path: root/src/vehicle_base.h
diff options
context:
space:
mode:
authorsmatz <smatz@openttd.org>2008-02-13 19:24:40 +0000
committersmatz <smatz@openttd.org>2008-02-13 19:24:40 +0000
commita0ddc43e92c33436bccc0d16ae935237e02a357e (patch)
treeaf07b8c3ed3437ba91111379ab438956940c60bb /src/vehicle_base.h
parentb7cd7919883ebec71a0e8ac88beb4bf72312e0d2 (diff)
downloadopenttd-a0ddc43e92c33436bccc0d16ae935237e02a357e.tar.xz
(svn r12134) -Change: count the number of ticks a vehicle was running this day to calculate running cost
-Fix [FS#1739]: vehicle profit is now counted with 8bit fract, so it is now shown properly in the vehicle details window
Diffstat (limited to 'src/vehicle_base.h')
-rw-r--r--src/vehicle_base.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/vehicle_base.h b/src/vehicle_base.h
index a19b80dfb..8d9c015d4 100644
--- a/src/vehicle_base.h
+++ b/src/vehicle_base.h
@@ -249,8 +249,9 @@ public:
CargoList cargo; ///< The cargo this vehicle is carrying
- byte day_counter; // increased by one for each day
- byte tick_counter; // increased by one for each tick
+ byte day_counter; ///< Increased by one for each day
+ byte tick_counter; ///< Increased by one for each tick
+ byte running_ticks; ///< Number of ticks this vehicle was not stopped this day
/* Begin Order-stuff */
Order current_order; ///< The current order (+ status, like: loading)
@@ -291,8 +292,8 @@ public:
uint16 load_unload_time_rem;
byte vehicle_flags; // Used for gradual loading and other miscellaneous things (@see VehicleFlags enum)
- Money profit_this_year;
- Money profit_last_year;
+ Money profit_this_year; ///< Profit this year << 8, low 8 bits are fract
+ Money profit_last_year; ///< Profit last year << 8, low 8 bits are fract
Money value;
GroupID group_id; ///< Index of group Pool array