File diff r25078:95767d321ffb → r25079:09d645764ffe
src/heightmap.cpp
Show inline comments
 
@@ -365,13 +365,13 @@ static void GrayscaleToMapHeights(uint i
 
				uint heightmap_height = map[img_row * img_width + img_col];
 

	
 
				if (heightmap_height > 0) {
 
					/* 0 is sea level.
 
					 * Other grey scales are scaled evenly to the available height levels > 0.
 
					 * (The coastline is independent from the number of height levels) */
 
					heightmap_height = 1 + (heightmap_height - 1) * _settings_game.construction.max_heightlevel / 255;
 
					heightmap_height = 1 + (heightmap_height - 1) * _settings_game.construction.map_height_limit / 255;
 
				}
 

	
 
				SetTileHeight(tile, heightmap_height);
 
			}
 
			/* Only clear the tiles within the map area. */
 
			if (IsInnerTile(tile)) {