OpenXRCamera.cs 460 B

12345678910111213141516171819202122232425
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4. public class OpenXRCamera : MonoBehaviour
  5. {
  6. public static OpenXRCamera Instance;
  7. public Transform head;
  8. void Awake()
  9. {
  10. if (Instance)
  11. {
  12. DestroyImmediate(gameObject);
  13. return;
  14. }
  15. Instance = this;
  16. Invoke("setFrame",3f);
  17. }
  18. void setFrame()
  19. {
  20. Application.targetFrameRate = 200;
  21. }
  22. }