MCPcopy Create free account
hub / github.com/WolfireGames/overgrowth / AS_SetConfigValueString

Function AS_SetConfigValueString

Source/Scripting/angelscript/asfuncs.cpp:6320–6332  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6318}
6319
6320void AS_SetConfigValueString(std::string key, std::string value) {
6321 if (key == "overall") {
6322 config.SetSettingsToPreset(value);
6323 config.ReloadStaticSettings();
6324 config.ReloadDynamicSettings();
6325 } else if (key == "difficulty_preset") {
6326 config.SetDifficultyPreset(value);
6327 config.ReloadDynamicSettings();
6328 } else {
6329 config.GetRef(key) = value;
6330 config.ReloadDynamicSettings();
6331 }
6332}
6333
6334void AS_SetConfigValueBool(std::string key, bool value) {
6335 config.GetRef(key) = value;

Callers

nothing calls this directly

Calls 5

SetSettingsToPresetMethod · 0.80
ReloadStaticSettingsMethod · 0.80
ReloadDynamicSettingsMethod · 0.80
SetDifficultyPresetMethod · 0.80
GetRefMethod · 0.45

Tested by

no test coverage detected