Mercurial > hg > openttd
diff src/script/script_config.hpp @ 20641:5eb738001301 draft
(svn r25592) -Fix [FS#5644]: Changing the script difficulty level in-game would also change the settings using the default even though they were not allowed to change in-game
author | rubidium <rubidium@openttd.org> |
---|---|
date | Fri, 12 Jul 2013 18:54:27 +0000 (2013-07-12) |
parents | 7fcb23b6305e |
children |
line wrap: on
line diff
--- a/src/script/script_config.hpp +++ b/src/script/script_config.hpp @@ -108,6 +108,16 @@ }; /** + * As long as the default of a setting has not been changed, the value of + * the setting is not stored. This to allow changing the difficulty setting + * without having to reset the script's config. However, when a setting may + * not be changed in game, we must "anchor" this value to what the setting + * would be at the time of starting. Otherwise changing the difficulty + * setting would change the setting's value (which isn't allowed). + */ + void AnchorUnchangeableSettings(); + + /** * Get the value of a setting for this config. It might fallback to his * 'info' to find the default value (if not set or if not-custom difficulty * level).