(svn r9371) -Feature: Add support for variable snow lines in the arctic climate, supplied

by newgrf files. When this is enabled forests cannot be built below the highest
snow line, and farms can't be built above it. Houses still use the
_opt.snow_line so they are all consistent, so to make them respect the snowline
you may want to use some newhouses features as well.
This commit is contained in:
maedhros
2007-03-20 13:47:00 +00:00
parent ad0b5de3da
commit 94db6aa1a2
13 changed files with 122 additions and 14 deletions

View File

@@ -12,6 +12,7 @@
#include "table/strings.h"
#include "functions.h"
#include "map.h"
#include "landscape.h"
#include "tile.h"
#include "town_map.h"
#include "vehicle.h"
@@ -864,7 +865,7 @@ static void TileLoop_Road(TileIndex tile)
{
switch (_opt.landscape) {
case LT_HILLY:
if (IsOnSnow(tile) != (GetTileZ(tile) > _opt.snow_line)) {
if (IsOnSnow(tile) != (GetTileZ(tile) > GetSnowLine())) {
ToggleSnow(tile);
MarkTileDirtyByTile(tile);
}