// Start is called before the first frame update void Start() { _gpf = FindObjectOfType <GamePreferenceFunctions>(); _slider = this.GetComponent <Slider>(); _vol = _slider.value; }
// Start is called before the first frame update void Awake() { _gpf = FindObjectOfType <GamePreferenceFunctions>(); _toggle = this.GetComponent <Toggle>(); _toggleStatus = _toggle.isOn; }