summaryrefslogtreecommitdiff
path: root/water_map.h
diff options
context:
space:
mode:
Diffstat (limited to 'water_map.h')
-rw-r--r--water_map.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/water_map.h b/water_map.h
index 9d63b0b5e..b0c04cc59 100644
--- a/water_map.h
+++ b/water_map.h
@@ -68,6 +68,12 @@ static inline DiagDirection GetLockDirection(TileIndex t)
return (DiagDirection)GB(_m[t].m5, 0, 2);
}
+static inline byte GetSection(TileIndex t)
+{
+ assert(GetWaterTileType(t) == WATER_LOCK || GetWaterTileType(t) == WATER_DEPOT);
+ return GB(_m[t].m5, 0, 4);
+}
+
static inline void MakeWater(TileIndex t)
{