diff options
author | tron <tron@openttd.org> | 2006-06-05 10:23:18 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2006-06-05 10:23:18 +0000 |
commit | eeeb8172e80eedf59109dced55fe72775340b59d (patch) | |
tree | 35c744c702db39785503087f611946cf4470097d /vehicle.c | |
parent | ddbcd9007c19f535bc4aca7cf01afed05a7b0b3f (diff) | |
download | openttd-eeeb8172e80eedf59109dced55fe72775340b59d.tar.xz |
(svn r5118) Add IsRoadVehInDepot{Stopped,}()
Diffstat (limited to 'vehicle.c')
-rw-r--r-- | vehicle.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -3,6 +3,7 @@ #include "stdafx.h" #include "openttd.h" #include "road_map.h" +#include "roadveh.h" #include "spritecache.h" #include "table/sprites.h" #include "table/strings.h" @@ -1996,7 +1997,7 @@ Trackdir GetVehicleTrackdir(const Vehicle* v) return TrackDirectionToTrackdir(FIND_FIRST_BIT(v->u.ship.state),v->direction); case VEH_Road: - if (v->u.road.state == 254) /* We'll assume the road vehicle is facing outwards */ + if (IsRoadVehInDepot(v)) /* We'll assume the road vehicle is facing outwards */ return DiagdirToDiagTrackdir(GetRoadDepotDirection(v->tile)); if (IsRoadStopTile(v->tile)) /* We'll assume the road vehicle is facing outwards */ |