using System.Collections; using System.Collections.Generic; using UnityEngine; public class showGameOverScreen : MonoBehaviour { public void show() { //顯示目前這個物件(背景圖) gameObject.SetActive(true); } public void replay() { //隱藏目前這個物件(背景圖) gameObject.SetActive(false); } public void myquit() { Application.Quit(); } void Start() { } // Update is called once per frame void Update() { if(Input.GetKeyDown(KeyCode.R)) { //隱藏目前這個物件(背景圖) gameObject.SetActive(false); } else if(Input.GetKeyDown(KeyCode.Q)) { Application.Quit(); } } }