From 3bcfe14cd1bd6aa2f400074c2b3084f2d5c841cd Mon Sep 17 00:00:00 2001 From: rubidium Date: Tue, 16 Oct 2007 19:48:58 +0000 Subject: (svn r11276) -Codechange: be more consistent with naming of some accessors. -Fix: make sure canals are never owned by water. Based on a patch by boekabart. --- src/station_map.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/station_map.h') diff --git a/src/station_map.h b/src/station_map.h index dd81c3f08..05d3abcba 100644 --- a/src/station_map.h +++ b/src/station_map.h @@ -154,6 +154,15 @@ static inline bool IsBuoyTile(TileIndex t) return IsTileType(t, MP_STATION) && IsBuoy(t); } +static inline bool IsCanalBuoyTile(TileIndex t) +{ + return IsBuoyTile(t) && !IsTileOwner(t, OWNER_WATER); +} + +static inline bool IsSeaBuoyTile(TileIndex t) +{ + return IsBuoyTile(t) && IsTileOwner(t, OWNER_WATER); +} static inline bool IsHangarTile(TileIndex t) { -- cgit v1.2.3-54-g00ecf