コード例 #1
0
 void Update()
 {
     if (Input.GetKeyDown(KeyCode.R))
     {
         CursorLockControl.UnlockCursor();
         MenuCanvasScript.Inicio();
     }
 }
コード例 #2
0
 // Start is called before the first frame update
 void Start()
 {
     _killCounter           = GameObject.FindWithTag("KillCounter").GetComponent <KillCounter>();
     _stageComplete         = GetComponent <TextMeshProUGUI>();
     _stageComplete.enabled = false;
     _audioManager          = GameObject.FindWithTag("AudioManager").GetComponent <AudioManagerScript>();
     _menu = GameObject.FindWithTag("IGMenu").GetComponent <MenuCanvasScript>();
 }
コード例 #3
0
 //Do this when the mouse is clicked over the selectable object this script is attached to.
 public void OnPointerDown(PointerEventData eventData)
 {
     CursorLockControl.LockCursor();
     MenuCanvasScript.Jogar();
 }