summaryrefslogtreecommitdiff
path: root/src/table
diff options
context:
space:
mode:
authorPatric Stout <truebrain@openttd.org>2021-03-24 14:48:12 +0100
committerPatric Stout <github@truebrain.nl>2021-03-26 12:22:32 +0100
commitcafe4eed6e482149eefe75393ad3a13e0f6e7ffe (patch)
treecc4188cdc13664f8ecc9750e0500e6e14c8d2d30 /src/table
parent7a886cb4d4538e8b94a7cbf633705a31a2856b47 (diff)
downloadopenttd-cafe4eed6e482149eefe75393ad3a13e0f6e7ffe.tar.xz
Feature: setting to indicate snow coverage for arctic climate (replaces snow line height)
Setting the snow coverage (in % of the map) makes a lot more sense to the human, while still allowing the niche player to set (by finding the correct %) a snow line height they like. This makes for easier defaults, as it decoupled terrain height from amount of snow. Maps can never be 100% snow, as we do not have sprites for coastal tiles. Internally, this calculates the best snow line height to approach this coverage as close as possible.
Diffstat (limited to 'src/table')
-rw-r--r--src/table/settings.ini17
1 files changed, 16 insertions, 1 deletions
diff --git a/src/table/settings.ini b/src/table/settings.ini
index 6e19e3ade..1a7eb12e3 100644
--- a/src/table/settings.ini
+++ b/src/table/settings.ini
@@ -1408,7 +1408,7 @@ cat = SC_BASIC
base = GameSettings
var = game_creation.snow_line_height
type = SLE_UINT8
-guiflags = SGF_NO_NETWORK
+guiflags = SGF_SCENEDIT_ONLY
def = DEF_SNOWLINE_HEIGHT
min = MIN_SNOWLINE_HEIGHT
max = MAX_SNOWLINE_HEIGHT
@@ -1418,6 +1418,21 @@ strhelp = STR_CONFIG_SETTING_SNOWLINE_HEIGHT_HELPTEXT
strval = STR_JUST_COMMA
cat = SC_BASIC
+[SDT_VAR]
+base = GameSettings
+var = game_creation.snow_coverage
+type = SLE_UINT8
+flags = SLF_NOT_IN_SAVE | SLF_NO_NETWORK_SYNC
+guiflags = SGF_NEWGAME_ONLY
+def = DEF_SNOW_COVERAGE
+min = 0
+max = 100
+interval = 10
+str = STR_CONFIG_SETTING_SNOW_COVERAGE
+strhelp = STR_CONFIG_SETTING_SNOW_COVERAGE_HELPTEXT
+strval = STR_CONFIG_SETTING_SNOW_COVERAGE_VALUE
+cat = SC_BASIC
+
[SDT_NULL]
length = 4
to = SLV_144