summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuXarick <43006711+SamuXarick@users.noreply.github.com>2020-03-31 15:47:29 +0100
committerCharles Pigott <charlespigott@googlemail.com>2020-03-31 22:33:19 +0100
commite7b901462e6d3b0b31c9861191cbdfd2fcbfc7aa (patch)
treefcdbee0564a9a67e453ece0f42a1fda40c194ffa
parent8f9654c5c658f2129838ba104a44f974f3388a2f (diff)
downloadopenttd-e7b901462e6d3b0b31c9861191cbdfd2fcbfc7aa.tar.xz
Doc: [Script] Make it clear random_deviation and CONFIG_RANDOM range upper bounds are inclusive
-rw-r--r--src/script/api/script_info_docs.hpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/script/api/script_info_docs.hpp b/src/script/api/script_info_docs.hpp
index be5d0cec6..36d2b859a 100644
--- a/src/script/api/script_info_docs.hpp
+++ b/src/script/api/script_info_docs.hpp
@@ -203,7 +203,7 @@ public:
/** Miscellaneous flags for Script settings. */
enum ScriptConfigFlags {
CONFIG_NONE, ///< Normal setting.
- CONFIG_RANDOM, ///< When randomizing the Script, pick any value between min_value and max_value.
+ CONFIG_RANDOM, ///< When randomizing the Script, pick any value between min_value and max_value (inclusive).
CONFIG_BOOLEAN, ///< This value is a boolean (either 0 (false) or 1 (true) ).
CONFIG_INGAME, ///< This setting can be changed while the Script is running.
CONFIG_DEVELOPER, ///< This setting will only be visible when the Script development tools are active.
@@ -230,8 +230,8 @@ public:
* - custom_value The default value if the custom difficulty level
* is selected. Required.
* - random_deviation If this property has a nonzero value, then the
- * actual value of the setting in game will be
- * user_configured_value + random(-random_deviation, random_deviation).
+ * actual value of the setting in game will be randomized in the range
+ * [user_configured_value - random_deviation, user_configured_value + random_deviation] (inclusive).
* Not allowed if the CONFIG_RANDOM flag is set, otherwise optional.
* - step_size The increase/decrease of the value every time the user
* clicks one of the up/down arrow buttons. Optional, default is 1.