Assignment for RMIT Mixed Reality in 2020
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
472 B

  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4. public class PauseAfter : MonoBehaviour
  5. {
  6. public float time = 1;
  7. public float currentTime;
  8. // Start is called before the first frame update
  9. void Start()
  10. {
  11. }
  12. // Update is called once per frame
  13. void Update()
  14. {
  15. currentTime = Time.time;
  16. if (currentTime >= time)
  17. UnityEditor.EditorApplication.isPaused = true;
  18. }
  19. }