diff options
author | rubidium <rubidium@openttd.org> | 2010-08-28 19:02:21 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2010-08-28 19:02:21 +0000 |
commit | 41a80490befda13df13115f3e272d05247bcf4a2 (patch) | |
tree | 1e3f9b83d4291b273b4ba04606837a956845a969 /src/tunnelbridge_cmd.cpp | |
parent | 3e67b4fe5fd94d181e44d8291d389868cd86182b (diff) | |
download | openttd-41a80490befda13df13115f3e272d05247bcf4a2.tar.xz |
(svn r20668) -Codechange: add (more) support for bridges over objects
Diffstat (limited to 'src/tunnelbridge_cmd.cpp')
-rw-r--r-- | src/tunnelbridge_cmd.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/tunnelbridge_cmd.cpp b/src/tunnelbridge_cmd.cpp index 315806f71..773d91e82 100644 --- a/src/tunnelbridge_cmd.cpp +++ b/src/tunnelbridge_cmd.cpp @@ -394,6 +394,7 @@ CommandCost CmdBuildBridge(TileIndex end_tile, DoCommandFlag flags, uint32 p1, u case MP_OBJECT: { const ObjectSpec *spec = ObjectSpec::GetByTile(tile); if ((spec->flags & OBJECT_FLAG_ALLOW_UNDER_BRIDGE) == 0) goto not_valid_below; + if (GetTileMaxZ(tile) + spec->height * TILE_HEIGHT > z_start) return_cmd_error(STR_ERROR_OBJECT_IN_THE_WAY); break; } |