1. DigitalDesignDude

    OP DigitalDesignDude Newbie
    Newcomer

    Joined:
    May 29, 2020
    Messages:
    2
    Country:
    Canada
    Hi, I hope this is good place to reach out to others about developing games for the vita using Unity!

    I got henkaku running on my vita and have been using Silica's Unity Tools to build .vpks with unity.

    It seems though that I can't limit the frame rate for my FPS game the same way I do on other devices like PC and Android.

    I just used the below code in a script but the vita seems to completely ignore it and instead runs anywhere from 45-60fps with a lot of screen tearing. I even have Vsync set to "Don't Sync" in Unity's Quality Settings.

    The game I'm building is intended to be played at 30fps so I hope limiting the frame rate will remove the screen tearing and also make other code in my game trigger with proper timing.

    Thank you for any input on this. I hope to release some game demos in the future to the homebrew browser once I get a handle on porting my games to the vita.



    public int targetFPS = 30;

    void Awake()
    {
    QualitySettings.vSyncCount = 0;
    Application.targetFrameRate = targetFPS;
    }

    void Update()
    {
    if(Application.targetFrameRate != targetFPS)
    Application.targetFrameRate = targetFPS;
    }
     
  2. DigitalDesignDude

    OP DigitalDesignDude Newbie
    Newcomer

    Joined:
    May 29, 2020
    Messages:
    2
    Country:
    Canada
    Figured out how to solve the issue!

    I set the vSync to 2 instead of 0 and the game used the proper frame rate and got rid of the screen tearing!

    QualitySettings.vSyncCount = 2;
     
Draft saved Draft deleted
Loading...

Hide similar threads Similar threads with keywords - framerate, Homebrew, Unity