mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-07-08 21:39:42 +01:00
Fix #8119: Update docking area when clearing a shore rail tile
This commit is contained in:
parent
21aa339901
commit
bb251f45fc
@ -1850,7 +1850,11 @@ static CommandCost ClearTile_Track(TileIndex tile, DoCommandFlag flags)
|
|||||||
if (ret.Failed()) return ret;
|
if (ret.Failed()) return ret;
|
||||||
|
|
||||||
/* The track was removed, and left a coast tile. Now also clear the water. */
|
/* The track was removed, and left a coast tile. Now also clear the water. */
|
||||||
if (flags & DC_EXEC) DoClearSquare(tile);
|
if (flags & DC_EXEC) {
|
||||||
|
bool remove = IsDockingTile(tile);
|
||||||
|
DoClearSquare(tile);
|
||||||
|
if (remove) RemoveDockingTile(tile);
|
||||||
|
}
|
||||||
cost.AddCost(_price[PR_CLEAR_WATER]);
|
cost.AddCost(_price[PR_CLEAR_WATER]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user