예제 #1
0
        private void ChangeQualityLevel(UIGenericSlider slider, float newValue)
        {
            var quality = (int)newValue;

            QualitySettings.SetQualityLevel(quality);
            QualitySettings.shadowDistance = _shadowDist[quality];
            QualitySettings.lodBias        = _lodBias[quality];
            slider.SetText(QualitySettings.names[quality]);
        }
예제 #2
0
        private void UpdateShadowCascades(UIGenericSlider slider, float cascades)
        {
            var c = Mathf.RoundToInt(cascades);

            if (c == 1)
            {
                c = 2;
            }
            else if (c == 3)
            {
                c = 4;
            }
            QualitySettings.shadowCascades = c;
        }
예제 #3
0
 private void UpdateShadowDistance(UIGenericSlider slider, float dist)
 {
     QualitySettings.shadowDistance = dist;
 }
예제 #4
0
 private void ChangeFov(UIGenericSlider slider, float newValue)
 {
     Player.Cam.fieldOfView = newValue;
 }
예제 #5
0
 private void UpdateVolume(UIGenericSlider slider, float newValue)
 {
     AudioListener.volume = newValue;
     slider.SetText(AudioListener.volume.ToString("F1"));
 }