summaryrefslogtreecommitdiff
path: root/src/object_cmd.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2011-11-04 10:28:20 +0000
committerrubidium <rubidium@openttd.org>2011-11-04 10:28:20 +0000
commitd0689c2924bd0c8793a61dfc9407673b1810d051 (patch)
treef9ff14ce87a9de6e9cbd4bfe89867096fd13c507 /src/object_cmd.cpp
parent69162621d81c82b832cccc8d59179fc0e4472af2 (diff)
downloadopenttd-d0689c2924bd0c8793a61dfc9407673b1810d051.tar.xz
(svn r23097) -Codechange: remove pointless multiplications by TILE_HEIGHT from the bridge code
Diffstat (limited to 'src/object_cmd.cpp')
-rw-r--r--src/object_cmd.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/object_cmd.cpp b/src/object_cmd.cpp
index 93d53898d..8c628d5b5 100644
--- a/src/object_cmd.cpp
+++ b/src/object_cmd.cpp
@@ -267,7 +267,7 @@ CommandCost CmdBuildObject(TileIndex tile, DoCommandFlag flags, uint32 p1, uint3
TILE_AREA_LOOP(t, ta) {
if (MayHaveBridgeAbove(t) && IsBridgeAbove(t) && (
!(spec->flags & OBJECT_FLAG_ALLOW_UNDER_BRIDGE) ||
- (GetTileMaxPixelZ(t) + spec->height * TILE_HEIGHT >= GetBridgePixelHeight(GetSouthernBridgeEnd(t))))) {
+ (GetTileMaxZ(t) + spec->height >= GetBridgeHeight(GetSouthernBridgeEnd(t))))) {
return_cmd_error(STR_ERROR_MUST_DEMOLISH_BRIDGE_FIRST);
}
}