summaryrefslogtreecommitdiff
path: root/src/water_cmd.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2010-08-27 22:29:13 +0000
committerrubidium <rubidium@openttd.org>2010-08-27 22:29:13 +0000
commit50769995c7934e8a12d7da1e28aa84b5264f3e59 (patch)
treef986f9d458f24245dabad68884476ca5afe65a5b /src/water_cmd.cpp
parent536bb704b7bd4d15302e6e2f0200184af151cb73 (diff)
downloadopenttd-50769995c7934e8a12d7da1e28aa84b5264f3e59.tar.xz
(svn r20640) -Add: support for water under objects
Diffstat (limited to 'src/water_cmd.cpp')
-rw-r--r--src/water_cmd.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/water_cmd.cpp b/src/water_cmd.cpp
index fcd834052..6f24956b1 100644
--- a/src/water_cmd.cpp
+++ b/src/water_cmd.cpp
@@ -499,6 +499,8 @@ static bool IsWateredTile(TileIndex tile, Direction from)
return IsTileOnWater(tile);
}
+ case MP_OBJECT: return IsTileOnWater(tile);
+
case MP_TUNNELBRIDGE: return GetTunnelBridgeTransportType(tile) == TRANSPORT_WATER && ReverseDiagDir(GetTunnelBridgeDirection(tile)) == DirToDiagDir(from);
default: return false;
@@ -935,6 +937,7 @@ FloodingBehaviour GetFloodingBehaviour(TileIndex tile)
/* FALL THROUGH */
case MP_STATION:
case MP_INDUSTRY:
+ case MP_OBJECT:
return (GetWaterClass(tile) == WATER_CLASS_SEA) ? FLOOD_ACTIVE : FLOOD_NONE;
case MP_RAILWAY: