mirror of https://github.com/OpenTTD/OpenTTD
Fix: part of a tile might not be marked dirty upon terraforming
parent
35dbd53682
commit
eaa3df1e8e
|
@ -310,7 +310,7 @@ CommandCost CmdTerraformLand(TileIndex tile, DoCommandFlag flags, uint32 p1, uin
|
||||||
/* Mark affected areas dirty. */
|
/* Mark affected areas dirty. */
|
||||||
for (TileIndexSet::const_iterator it = ts.dirty_tiles.begin(); it != ts.dirty_tiles.end(); it++) {
|
for (TileIndexSet::const_iterator it = ts.dirty_tiles.begin(); it != ts.dirty_tiles.end(); it++) {
|
||||||
MarkTileDirtyByTile(*it);
|
MarkTileDirtyByTile(*it);
|
||||||
TileIndexToHeightMap::const_iterator new_height = ts.tile_to_new_height.find(tile);
|
TileIndexToHeightMap::const_iterator new_height = ts.tile_to_new_height.find(*it);
|
||||||
if (new_height == ts.tile_to_new_height.end()) continue;
|
if (new_height == ts.tile_to_new_height.end()) continue;
|
||||||
MarkTileDirtyByTile(*it, 0, new_height->second);
|
MarkTileDirtyByTile(*it, 0, new_height->second);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue