(svn r25849) -Codechange: Introduce IsTileFlat to not compute full slope information for situations when we only want to know if a tile is flat or not (cirdan, LordAro)
This commit is contained in:
@@ -249,8 +249,7 @@ static void TileLoop_Clear(TileIndex tile)
|
||||
/* If the tile is at any edge flood it to prevent maps without water. */
|
||||
if (_settings_game.construction.freeform_edges && DistanceFromEdge(tile) == 1) {
|
||||
int z;
|
||||
Slope slope = GetTileSlope(tile, &z);
|
||||
if (z == 0 && slope == SLOPE_FLAT) {
|
||||
if (IsTileFlat(tile, &z) && z == 0) {
|
||||
DoFloodTile(tile);
|
||||
MarkTileDirtyByTile(tile);
|
||||
return;
|
||||
|
Reference in New Issue
Block a user