diff options
author | Samu <dj_samu@hotmail.com> | 2020-01-17 19:58:07 +0000 |
---|---|---|
committer | Niels Martin Hansen <nielsm@indvikleren.dk> | 2020-02-09 20:56:30 +0100 |
commit | 30fe0015e2152e0cada8997e760271f31a001a1a (patch) | |
tree | a47f1d2f5ddd99f6f6eae16fbadbf800a678c378 /src | |
parent | e31d75c926103edce3751195f8e178ad305c0e39 (diff) | |
download | openttd-30fe0015e2152e0cada8997e760271f31a001a1a.tar.xz |
Fix #7944: Demolishing locks built on rivers didn't always restore the river
Diffstat (limited to 'src')
-rw-r--r-- | src/water_cmd.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/water_cmd.cpp b/src/water_cmd.cpp index d1ab57f34..12195d8dc 100644 --- a/src/water_cmd.cpp +++ b/src/water_cmd.cpp @@ -301,7 +301,7 @@ static CommandCost DoBuildLock(TileIndex tile, DiagDirection dir, DoCommandFlag if (ret.Failed()) return ret; /* middle tile */ - WaterClass wc_middle = IsWaterTile(tile) ? GetWaterClass(tile) : WATER_CLASS_CANAL; + WaterClass wc_middle = HasTileWaterGround(tile) ? GetWaterClass(tile) : WATER_CLASS_CANAL; ret = DoCommand(tile, 0, 0, flags, CMD_LANDSCAPE_CLEAR); if (ret.Failed()) return ret; cost.AddCost(ret); |