Пример #1
0
    public void SetFrameRate(int index)
    {
        frameOption.SetValue(index);
        switch (index)
        {
        case 0: Application.targetFrameRate = 30;
            break;

        case 1:
            Application.targetFrameRate = 40;
            break;

        case 2:
            Application.targetFrameRate = 45;
            break;

        case 3:
            Application.targetFrameRate = 50;
            break;

        case 4:
            Application.targetFrameRate = 60;
            break;

        case 5:
            Application.targetFrameRate = 80;
            break;

        case 6:
            Application.targetFrameRate = 90;
            break;

        case 7:
            Application.targetFrameRate = 120;
            break;

        default:
            break;
        }
    }
Пример #2
0
 public void SetSync(int index)
 {
     syncOption.SetValue(index);
     QualitySettings.vSyncCount = index;
 }