mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-16 02:24:11 +01:00
Add $reset directive to config processor for setting a config entry to default value (#59874)
added this so that the value of INTERVIEW_QUESTIONS (and subsequently any other string list) can be overridden without much issue by additional config files. i also changed the functionality of default on config_entry as it seemed to be counterintuitive to have it be set to the initial value of the config_entry. in my opinion this should be a compile-time default, and so i've refactored the code such that default now contains the actual default, and the config_entry_value is set at intialization.
This commit is contained in:
@@ -65,11 +65,11 @@ GLOBAL_VAR_INIT(total_runtimes_skipped, 0)
|
||||
configured_error_silence_time = CONFIG_GET(number/error_silence_time)
|
||||
else
|
||||
var/datum/config_entry/CE = /datum/config_entry/number/error_cooldown
|
||||
configured_error_cooldown = initial(CE.config_entry_value)
|
||||
configured_error_cooldown = initial(CE.default)
|
||||
CE = /datum/config_entry/number/error_limit
|
||||
configured_error_limit = initial(CE.config_entry_value)
|
||||
configured_error_limit = initial(CE.default)
|
||||
CE = /datum/config_entry/number/error_silence_time
|
||||
configured_error_silence_time = initial(CE.config_entry_value)
|
||||
configured_error_silence_time = initial(CE.default)
|
||||
|
||||
|
||||
//Each occurence of a unique error adds to its cooldown time...
|
||||
|
||||
Reference in New Issue
Block a user