コード例 #1
0
        //Load local values manually.
        public void LoadPrefs()
        {
            setting   = Param.GetPlayerPrefs(SaveKey, setting);
            speedStep = Mathf.Clamp(setting.GetFloat(SPEED_STEP_KEY, speedStep), STEP_MIN, 2.0f);
            pitchStep = Mathf.Clamp(setting.GetFloat(PITCH_STEP_KEY, pitchStep), STEP_MIN, 2.0f);

            float oldSpeed = sSpeed;    //For check the change of value.

            SetSpeed(setting.GetFloat(SPEED_KEY, sSpeed));
            if (oldSpeed != sSpeed && OnSpeedChanged != null)
            {
                OnSpeedChanged.Invoke(sSpeed);
            }

            float oldPitch = sPitch;    //For check the change of value.

            SetPitch(setting.GetFloat(PITCH_KEY, sPitch));
            if (oldPitch != sPitch && OnPitchChanged != null)
            {
                OnPitchChanged.Invoke(sPitch);
            }
        }
コード例 #2
0
 //Load local values manually.
 public void LoadPrefs()
 {
     setting = Param.GetPlayerPrefs(SaveKey, setting);
     Locale  = setting.GetString(LOCALE_KEY, Locale);
 }
コード例 #3
0
        //Load local values manually.
        public void LoadPrefs()
        {
            Param param = Param.GetPlayerPrefs(SaveKey);

            SetValue(param);
        }
コード例 #4
0
 //Load local values manually.
 public void LoadPrefs()
 {
     setting  = Param.GetPlayerPrefs(SaveKey, setting);
     Language = ConvertToSystemLanguage(setting.GetString(LANGUAGE_KEY, Language.ToString()));
 }