(svn r18976) -Fix: Estimating the cost of removing statues could clear the presence flag in the town.

This commit is contained in:
frosch
2010-01-31 20:56:24 +00:00
parent 6ade772f01
commit 6c74e1c4f2

View File

@@ -287,9 +287,11 @@ static CommandCost ClearTile_Unmovable(TileIndex tile, DoCommandFlag flags)
if (IsStatue(tile)) {
if (flags & DC_AUTO) return_cmd_error(STR_ERROR_OBJECT_IN_THE_WAY);
TownID town = GetStatueTownID(tile);
ClrBit(Town::Get(town)->statues, GetTileOwner(tile));
SetWindowDirty(WC_TOWN_AUTHORITY, town);
if (flags & DC_EXEC) {
TownID town = GetStatueTownID(tile);
ClrBit(Town::Get(town)->statues, GetTileOwner(tile));
SetWindowDirty(WC_TOWN_AUTHORITY, town);
}
}
if (flags & DC_EXEC) {