diff options
author | rubidium <rubidium@openttd.org> | 2010-10-08 21:08:38 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2010-10-08 21:08:38 +0000 |
commit | 7bbc19288f33a2c68daebdc9c31de84ef91e37c9 (patch) | |
tree | cd3d905d9301d0df31454c25e15713cb3551092b /src/object_cmd.cpp | |
parent | 322e4ab86fe21c7522ae1501aba175a8f7fa1e5d (diff) | |
download | openttd-7bbc19288f33a2c68daebdc9c31de84ef91e37c9.tar.xz |
(svn r20909) -Fix [FS#4137]: don't see coasts as water for object construction
Diffstat (limited to 'src/object_cmd.cpp')
-rw-r--r-- | src/object_cmd.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/object_cmd.cpp b/src/object_cmd.cpp index cedec4188..0ddcf3664 100644 --- a/src/object_cmd.cpp +++ b/src/object_cmd.cpp @@ -166,7 +166,7 @@ CommandCost CmdBuildObject(TileIndex tile, DoCommandFlag flags, uint32 p1, uint3 bool allow_water = (spec->flags & (OBJECT_FLAG_BUILT_ON_WATER | OBJECT_FLAG_NOT_ON_LAND)) != 0; bool allow_ground = (spec->flags & OBJECT_FLAG_NOT_ON_LAND) == 0; TILE_AREA_LOOP(t, ta) { - if (HasTileWaterClass(t) && IsTileOnWater(t)) { + if (HasTileWaterClass(t) && IsTileOnWater(t) && !IsCoastTile(t)) { if (!allow_water) return_cmd_error(STR_ERROR_CAN_T_BUILD_ON_WATER); if (!IsWaterTile(t)) { /* Normal water tiles don't have to be cleared. For all other tile types clear |