From 55b93b1c058aff7fb67dad186c31855acb2a5724 Mon Sep 17 00:00:00 2001 From: rubidium Date: Tue, 19 Jun 2007 21:15:14 +0000 Subject: (svn r10230) -Fix [FS#594]: terraforming wipes out canals. Now you always have to remove the canal before terraforming, instead of "just" removing the canal. --- src/water_map.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/water_map.h') diff --git a/src/water_map.h b/src/water_map.h index cb20bd15a..77fce0a17 100644 --- a/src/water_map.h +++ b/src/water_map.h @@ -45,6 +45,11 @@ static inline bool IsCoast(TileIndex t) return GetWaterTileType(t) == WATER_TILE_COAST; } +static inline bool IsCanal(TileIndex t) +{ + return GetWaterTileType(t) == WATER_TILE_CLEAR && GetTileOwner(t) != OWNER_WATER; +} + static inline bool IsClearWaterTile(TileIndex t) { return IsTileType(t, MP_WATER) && IsWater(t) && GetTileSlope(t, NULL) == SLOPE_FLAT; -- cgit v1.2.3-54-g00ecf