summaryrefslogtreecommitdiff
path: root/viewport.c
diff options
context:
space:
mode:
authorcelestar <celestar@openttd.org>2005-07-16 23:47:37 +0000
committercelestar <celestar@openttd.org>2005-07-16 23:47:37 +0000
commitde19186be3001000286e0893cd0e2da2f3f5925d (patch)
treeb32b3e56573203f32982f2fc2b3966529a6d1857 /viewport.c
parent594dd34e84e78b03e1cdeb7cf262707fd714a5fa (diff)
downloadopenttd-de19186be3001000286e0893cd0e2da2f3f5925d.tar.xz
(svn r2595) -Codechange: Introduced "IsSteepTileh" to find whether a tile is steep
(i.e. spans two height levels) and use it throughout the code. -Codechange: Add CanBuildDepotByTileh to find if a tile is suitable to build a depot on it. Wraps some bitmagic which seems quite unreadable at first glance
Diffstat (limited to 'viewport.c')
-rw-r--r--viewport.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/viewport.c b/viewport.c
index 44e8e557a..3cb0bda0e 100644
--- a/viewport.c
+++ b/viewport.c
@@ -669,7 +669,7 @@ static void DrawTileSelection(const TileInfo *ti)
byte z = ti->z;
if (ti->tileh & 8) {
z += 8;
- if (!(ti->tileh & 2) && (ti->tileh & 0x10)) {
+ if (!(ti->tileh & 2) && (IsSteepTileh(ti->tileh))) {
z += 8;
}
}