src/clear_cmd.cpp
changeset 6343 76d17f784c13
parent 6248 e4a2ed7e5613
child 6357 f0f5e7d1713c
--- a/src/clear_cmd.cpp	Tue Mar 20 10:06:39 2007 +0000
+++ b/src/clear_cmd.cpp	Tue Mar 20 13:47:00 2007 +0000
@@ -16,6 +16,7 @@
 #include "tunnel_map.h"
 #include "bridge_map.h"
 #include "bridge.h"
+#include "landscape.h"
 #include "variables.h"
 #include "table/sprites.h"
 #include "unmovable_map.h"
@@ -620,7 +621,7 @@
 /* convert into snowy tiles */
 static void TileLoopClearAlps(TileIndex tile)
 {
-	int k = GetTileZ(tile) - _opt.snow_line + TILE_HEIGHT;
+	int k = GetTileZ(tile) - GetSnowLine() + TILE_HEIGHT;
 
 	if (k < 0) { // well below the snow line
 		if (!IsClearGround(tile, CLEAR_SNOW)) return;