summaryrefslogtreecommitdiff
path: root/ttd.h
diff options
context:
space:
mode:
authormatthijs <matthijs@openttd.org>2005-05-02 23:59:11 +0000
committermatthijs <matthijs@openttd.org>2005-05-02 23:59:11 +0000
commit6eb094c72622b39bceff8293c3446e57d21c62f0 (patch)
treecad8daa1ee5542d4e8fefcbf2e2825e3f35fdb47 /ttd.h
parent2ab5eee78b495ec73049c8446a0ed37ab4ff0920 (diff)
downloadopenttd-6eb094c72622b39bceff8293c3446e57d21c62f0.tar.xz
(svn r2256) - Fix: Trains cannot find a depot when they are in a tunnel. (glx)
- Add: GetVehicleTrackdir() helper function. - Codechange: Moved SortStruct from vehicle_gui.h to ttd.h, so the dependency from vehicle.h on vehicle_gui.h could be removed. - Codechange: Typedeffed the VehicleTypes struct so it can be used as the type for Vehicle.type instead of "byte". - Codechange: Removed prototype for VehicleSorter(), which had no implementation anymore and was never called.
Diffstat (limited to 'ttd.h')
-rw-r--r--ttd.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/ttd.h b/ttd.h
index 94722b246..fcb5b9159 100644
--- a/ttd.h
+++ b/ttd.h
@@ -25,6 +25,15 @@ typedef struct Pair {
int b;
} Pair;
+/**
+ * Is used as a general sortable struct (using qsort and friends). Is used for
+ * sorting vehicles and stations at the moment
+ */
+typedef struct SortStruct {
+ uint32 index;
+ byte owner;
+} SortStruct;
+
typedef struct YearMonthDay {
int year, month, day;
} YearMonthDay;