summaryrefslogtreecommitdiff
path: root/src/ai/api/ai_tunnel.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2011-11-04 10:25:33 +0000
committerrubidium <rubidium@openttd.org>2011-11-04 10:25:33 +0000
commitb167c0a3967a62b4cbe98a12f2c4d932ee8df510 (patch)
tree59ae32bc087b05c1d2c3e990706f3efed22d8d93 /src/ai/api/ai_tunnel.cpp
parentecbc56a67711bfc37d751f9c3bff2a464ea03564 (diff)
downloadopenttd-b167c0a3967a62b4cbe98a12f2c4d932ee8df510.tar.xz
(svn r23095) -Codechange: remove useless divisions/multiplications by TILE_HEIGHT for the AI API code
Diffstat (limited to 'src/ai/api/ai_tunnel.cpp')
-rw-r--r--src/ai/api/ai_tunnel.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ai/api/ai_tunnel.cpp b/src/ai/api/ai_tunnel.cpp
index d82d8d68e..99aec30c4 100644
--- a/src/ai/api/ai_tunnel.cpp
+++ b/src/ai/api/ai_tunnel.cpp
@@ -30,7 +30,7 @@
if (IsTunnelTile(tile)) return ::GetOtherTunnelEnd(tile);
uint start_z;
- Slope start_tileh = ::GetTilePixelSlope(tile, &start_z);
+ Slope start_tileh = ::GetTileSlope(tile, &start_z);
DiagDirection direction = ::GetInclinedSlopeDirection(start_tileh);
if (direction == INVALID_DIAGDIR) return INVALID_TILE;
@@ -40,7 +40,7 @@
tile += delta;
if (!::IsValidTile(tile)) return INVALID_TILE;
- ::GetTilePixelSlope(tile, &end_z);
+ ::GetTileSlope(tile, &end_z);
} while (start_z != end_z);
return tile;