summaryrefslogtreecommitdiff
path: root/src/vehicle.h
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2007-06-22 11:58:59 +0000
committerrubidium <rubidium@openttd.org>2007-06-22 11:58:59 +0000
commite5c352818d7edfdc5219e4c82f7d5b2083b2b72d (patch)
treefd6fbc96b8d23bef18ed7267fa8174e1689c8e78 /src/vehicle.h
parent6159f58948763ed39a457e6ff825a735eea06b23 (diff)
downloadopenttd-e5c352818d7edfdc5219e4c82f7d5b2083b2b72d.tar.xz
(svn r10266) -Codechange: keep track of the origin, time of travel and accumulated feeder share (transfers) of individual pieces of cargo. This means that cargo isn't thrown on a big pile when it's put in a station or unloaded at a station, however the GUI does not reflect these changes yet so you will not actually see it.
Diffstat (limited to 'src/vehicle.h')
-rw-r--r--src/vehicle.h10
1 files changed, 3 insertions, 7 deletions
diff --git a/src/vehicle.h b/src/vehicle.h
index 9ab0bb6de..5efb14a7a 100644
--- a/src/vehicle.h
+++ b/src/vehicle.h
@@ -9,6 +9,7 @@
#include "order.h"
#include "rail.h"
#include "road.h"
+#include "cargopacket.h"
#include "texteff.hpp"
/** The returned bits of VehicleEnterTile. */
@@ -265,12 +266,10 @@ struct Vehicle {
StationID last_station_visited;
CargoID cargo_type; // type of cargo this vehicle is carrying
- byte cargo_days; // how many days have the pieces been in transit
- StationID cargo_source; // source of cargo
- TileIndex cargo_source_xy; //< stores the Tile where the source station is located, in case it is removed
uint16 cargo_cap; // total capacity
- uint16 cargo_count; // how many pieces are used
byte cargo_subtype; ///< Used for livery refits (NewGRF variations)
+ 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
@@ -312,13 +311,10 @@ struct Vehicle {
bool leave_depot_instantly; // NOSAVE: stores if the vehicle needs to leave the depot it just entered. Used by autoreplace
uint16 load_unload_time_rem;
- uint16 cargo_paid_for; // How much of the cargo currently on board has been paid for.
byte vehicle_flags; // Used for gradual loading and other miscellaneous things (@see VehicleFlags enum)
Money profit_this_year;
Money profit_last_year;
- Money cargo_feeder_share; ///< value of feeder pickup to be paid for on delivery of cargo
- TileIndex cargo_loaded_at_xy; ///< tile index where feeder cargo was loaded
Money value;
GroupID group_id; ///< Index of group Pool array