1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-23 22:49:09 +00:00

(svn r18719) -Feature: don't delete the rough/rocky status of a tile when it's covered by snow, this allows rocky tiles under snow if you have a variable snowline

This commit is contained in:
yexo
2010-01-04 18:33:43 +00:00
parent 3e131e2fec
commit b378e82676
10 changed files with 147 additions and 38 deletions

View File

@@ -158,11 +158,11 @@ static void TileLoopClearAlps(TileIndex tile)
if (k < 0) {
/* Below the snow line, do nothing if no snow. */
if (!IsClearGround(tile, CLEAR_SNOW)) return;
if (!IsSnowTile(tile)) return;
} else {
/* At or above the snow line, make snow tile if needed. */
if (!IsClearGround(tile, CLEAR_SNOW)) {
SetClearGroundDensity(tile, CLEAR_SNOW, 0);
if (!IsSnowTile(tile)) {
MakeSnow(tile);
MarkTileDirtyByTile(tile);
return;
}
@@ -177,7 +177,7 @@ static void TileLoopClearAlps(TileIndex tile)
AddClearDensity(tile, -1);
} else {
/* Density at the required level. */
if (k < 0) SetClearGroundDensity(tile, CLEAR_GRASS, 3);
if (k < 0) ClearSnow(tile);
}
MarkTileDirtyByTile(tile);
}