diff options
author | rubidium <rubidium@openttd.org> | 2008-06-11 13:54:01 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2008-06-11 13:54:01 +0000 |
commit | 7f6382badd3ea4f2c21920c9951997d4b431d0a2 (patch) | |
tree | 93d0cf5e2656fbaec389d945c2682c766b5756c8 /src/yapf | |
parent | dc5ceacd77b490ea7b1c719753704a744a80377c (diff) | |
download | openttd-7f6382badd3ea4f2c21920c9951997d4b431d0a2.tar.xz |
(svn r13464) -Codechange: support NewGRF Action 0x05, type 12.
Diffstat (limited to 'src/yapf')
-rw-r--r-- | src/yapf/follow_track.hpp | 2 | ||||
-rw-r--r-- | src/yapf/yapf_ship.cpp | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/src/yapf/follow_track.hpp b/src/yapf/follow_track.hpp index 362a3d355..d3c9c4515 100644 --- a/src/yapf/follow_track.hpp +++ b/src/yapf/follow_track.hpp @@ -264,7 +264,7 @@ protected: } // tunnel holes and bridge ramps can be entered only from proper direction - if (!IsWaterTT() && IsTileType(m_new_tile, MP_TUNNELBRIDGE)) { + if (IsTileType(m_new_tile, MP_TUNNELBRIDGE)) { if (IsTunnel(m_new_tile)) { if (!m_is_tunnel) { DiagDirection tunnel_enterdir = GetTunnelBridgeDirection(m_new_tile); diff --git a/src/yapf/yapf_ship.cpp b/src/yapf/yapf_ship.cpp index bf8d00e64..9c935388f 100644 --- a/src/yapf/yapf_ship.cpp +++ b/src/yapf/yapf_ship.cpp @@ -109,6 +109,9 @@ public: /* new trackdir does not match the next one when going straight */ c += 10; } + + c += YAPF_TILE_LENGTH * tf->m_tiles_skipped; + // apply it n.m_cost = n.m_parent->m_cost + c; return true; |