summaryrefslogtreecommitdiff
path: root/src/station.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
commitfc201d4ad8268234ce67d2ea1e49d470ab0c2004 (patch)
treefd6fbc96b8d23bef18ed7267fa8174e1689c8e78 /src/station.h
parentdc82eeb2ae166f3284cda1aa265045c10c29b4c2 (diff)
downloadopenttd-fc201d4ad8268234ce67d2ea1e49d470ab0c2004.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/station.h')
-rw-r--r--src/station.h18
1 files changed, 5 insertions, 13 deletions
diff --git a/src/station.h b/src/station.h
index 6a70bcc34..10ba050c1 100644
--- a/src/station.h
+++ b/src/station.h
@@ -12,34 +12,26 @@
#include "tile.h"
#include "road.h"
#include "newgrf_station.h"
+#include "cargopacket.h"
#include <list>
-static const StationID INVALID_STATION = 0xFFFF;
static const byte INITIAL_STATION_RATING = 175;
struct GoodsEntry {
GoodsEntry() :
- waiting_acceptance(0),
- unload_pending(0),
+ acceptance(false),
days_since_pickup(0),
rating(INITIAL_STATION_RATING),
- enroute_from(INVALID_STATION),
- enroute_from_xy(INVALID_TILE),
last_speed(0),
- last_age(255),
- feeder_profit(0)
+ last_age(255)
{}
- uint16 waiting_acceptance;
- uint16 unload_pending; ///< records how much cargo is awaiting transfer during gradual loading to allow correct fee calc
+ bool acceptance;
byte days_since_pickup;
byte rating;
- StationID enroute_from;
- TileIndex enroute_from_xy;
- byte enroute_time;
byte last_speed;
byte last_age;
- Money feeder_profit;
+ CargoList cargo; ///< The cargo packets of cargo waiting in this station
};
/** A Stop for a Road Vehicle */