An open API service indexing awesome lists of open source software.

https://github.com/owl-man/fps-controller-for-unity

FPS (Frames Per Second) Controller for Unity
https://github.com/owl-man/fps-controller-for-unity

fps helpful-tool unity vsync

Last synced: 2 months ago
JSON representation

FPS (Frames Per Second) Controller for Unity

Awesome Lists containing this project

README

        

# FPS (Frame Per Second) Controller for Unity

By moving the **FPS controller.cs** script to the folder with your other scripts, you can limit the frame rate using the inspector in the Unity
(changing the **FPS** integer variable) or by calling the **SetFPS** method. Also, through the inspector (changing the **isVSyncActive** bool variable) or by calling the **DisableVSync/EnableVSync** method, you can turn off and turn on VSync (Vertical Sync). All these methods are located in the **FPS Controller** class, which can be accessed using a singleton.

Example:

using UnityEngine;

public class Test : MonoBehaviour
{
private FPSController FPSCntrl;

private void Start()
{
FPSCntrl = FPSController.instance;

FPSCntrl.DisableVSync();
FPSCntrl.SetFPS(60);
}
}

***FPS Controller script must be located in the scene and only once, to use its functions***