summaryrefslogtreecommitdiff
path: root/src/yapf/yapf_rail.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-05-22 22:33:05 +0000
committerrubidium <rubidium@openttd.org>2009-05-22 22:33:05 +0000
commitc4b627af422075ce4a0e1026c52f871dd3f146c0 (patch)
treefebaea249dc307b4b619aeff09e353677bbbcd84 /src/yapf/yapf_rail.cpp
parent80e94b9bb15f846189e98f1f457afe2b96ba2b58 (diff)
downloadopenttd-c4b627af422075ce4a0e1026c52f871dd3f146c0.tar.xz
(svn r16392) -Codechange: move some variables (the ones that aren't caches) from VehicleRail to Train
Diffstat (limited to 'src/yapf/yapf_rail.cpp')
-rw-r--r--src/yapf/yapf_rail.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/yapf/yapf_rail.cpp b/src/yapf/yapf_rail.cpp
index 2c05c68ff..7b4e4e9bb 100644
--- a/src/yapf/yapf_rail.cpp
+++ b/src/yapf/yapf_rail.cpp
@@ -550,7 +550,7 @@ bool YapfCheckReverseTrain(const Vehicle *vt)
int reverse_penalty = 0;
- if (v->u.rail.track == TRACK_BIT_WORMHOLE) {
+ if (v->track == TRACK_BIT_WORMHOLE) {
/* front in tunnel / on bridge */
DiagDirection dir_into_wormhole = GetTunnelBridgeDirection(tile);
@@ -565,7 +565,7 @@ bool YapfCheckReverseTrain(const Vehicle *vt)
reverse_penalty -= DistanceManhattan(cur_tile, tile) * YAPF_TILE_LENGTH;
}
- if (last_veh->u.rail.track == TRACK_BIT_WORMHOLE) {
+ if (last_veh->track == TRACK_BIT_WORMHOLE) {
/* back in tunnel / on bridge */
DiagDirection dir_into_wormhole = GetTunnelBridgeDirection(tile_rev);