using System.Collections; using System.Collections.Generic; using UnityEngine; public class ButtonEnd : MonoBehaviour { public showGameOverScreen showscreen1; public void buttonEnd() { //錯誤做法:無法顯示 //GameObject.Find("背景圖").SetActive(true); //正確做法:可以顯示背景圖片 showscreen1.show(); } void Start() { } // Update is called once per frame void Update() { } }