summaryrefslogtreecommitdiff
path: root/src/tgp.cpp
diff options
context:
space:
mode:
authorYexo <Yexo@openttd.org>2009-01-23 00:18:27 +0000
committerYexo <Yexo@openttd.org>2009-01-23 00:18:27 +0000
commitbd08be44ea9b0d72e4394a35e5a1071cb08afec6 (patch)
tree232792793dda47b4f71a5654badb587cde9fbfc5 /src/tgp.cpp
parent50956b4f7ae2cdb5b8dc52e517c98123a466e666 (diff)
downloadopenttd-bd08be44ea9b0d72e4394a35e5a1071cb08afec6.tar.xz
(svn r15212) -Feature [FS#2566]: Change the dropdown box where you can chose which edges will be water to 4 pushbuttons (based on patch by planetmaker).
Diffstat (limited to 'src/tgp.cpp')
-rw-r--r--src/tgp.cpp8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/tgp.cpp b/src/tgp.cpp
index e72acf5e0..12bfbf69b 100644
--- a/src/tgp.cpp
+++ b/src/tgp.cpp
@@ -552,13 +552,6 @@ static void HeightMapAdjustWaterLevel(amplitude_t water_percent, height_t h_max_
static double perlin_coast_noise_2D(const double x, const double y, const double p, const int prime);
-enum Borders {
- BORDER_NE = 0,
- BORDER_SE = 1,
- BORDER_SW = 2,
- BORDER_NW = 3,
-};
-
/**
* This routine sculpts in from the edge a random amount, again a Perlin
* sequence, to avoid the rigid flat-edge slopes that were present before. The
@@ -725,6 +718,7 @@ static void HeightMapNormalize()
HeightMapAdjustWaterLevel(water_percent, h_max_new);
byte water_borders = _settings_game.construction.freeform_edges ? _settings_game.game_creation.water_borders : 0xF;
+ if (water_borders == BORDERS_RANDOM) water_borders = GB(Random(), 0, 4);
HeightMapCoastLines(water_borders);
HeightMapSmoothSlopes(roughness);