diff options
author | Darkvater <Darkvater@openttd.org> | 2006-09-05 23:21:41 +0000 |
---|---|---|
committer | Darkvater <Darkvater@openttd.org> | 2006-09-05 23:21:41 +0000 |
commit | 7e4d0f112edbe2acb8ceebdf3161fa7c90cd66f9 (patch) | |
tree | f2f14fca9ac095b0bf6b46615035b8c207e3ce66 /yapf | |
parent | a53c92464f2d87bcb9e8b31a1f68d5e26e29aded (diff) | |
download | openttd-7e4d0f112edbe2acb8ceebdf3161fa7c90cd66f9.tar.xz |
(svn r6406) -Codechange: Rename TileOffsByDir to TileOffsByDiagDir because it accepts
DiagDirections, and add TileOffsByDir that handles Directions.
-Codechange: Make the treeloop use TileOffsByDir().
Diffstat (limited to 'yapf')
-rw-r--r-- | yapf/follow_track.hpp | 4 | ||||
-rw-r--r-- | yapf/yapf_ship.cpp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/yapf/follow_track.hpp b/yapf/follow_track.hpp index 218de53b4..a197ef8bb 100644 --- a/yapf/follow_track.hpp +++ b/yapf/follow_track.hpp @@ -78,7 +78,7 @@ protected: m_tiles_skipped = 0; // normal or station tile - TileIndexDiff diff = TileOffsByDir(m_exitdir); + TileIndexDiff diff = TileOffsByDiagDir(m_exitdir); m_new_tile = TILE_ADD(m_old_tile, diff); // special handling for stations @@ -194,7 +194,7 @@ protected: // how big step we must do to get to the last platform tile; m_tiles_skipped = length - 1; // move to the platform end - TileIndexDiff diff = TileOffsByDir(m_exitdir); + TileIndexDiff diff = TileOffsByDiagDir(m_exitdir); diff *= m_tiles_skipped; m_new_tile = TILE_ADD(m_new_tile, diff); return true; diff --git a/yapf/yapf_ship.cpp b/yapf/yapf_ship.cpp index 728c41cd9..038bdba43 100644 --- a/yapf/yapf_ship.cpp +++ b/yapf/yapf_ship.cpp @@ -44,7 +44,7 @@ public: } // move back to the old tile/trackdir (where ship is coming from) - TileIndex src_tile = TILE_ADD(tile, TileOffsByDir(ReverseDiagDir(enterdir))); + TileIndex src_tile = TILE_ADD(tile, TileOffsByDiagDir(ReverseDiagDir(enterdir))); Trackdir trackdir = GetVehicleTrackdir(v); assert(IsValidTrackdir(trackdir)); |