private void Awake() { this.RuntimeAssert(!string.IsNullOrEmpty(configKeyName), "Empty configKeyName."); slider = GetComponent <Slider>(); configManager = Utils.FindNovaGameController().ConfigManager; var def = configManager.GetDefinition(configKeyName); this.RuntimeAssert(def != null, $"Config Key \"{configKeyName}\" Definition not Found."); slider.maxValue = def.max ?? 1; slider.minValue = def.min ?? 0; slider.wholeNumbers = def.whole == true; }