123456789101112131415161718192021222324252627282930313233343536373839404142 |
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- using UnityEngine.SceneManagement;
- public class GameManage : MonoBehaviour
- {
- private static GameManage instance;
- public static GameManage Instance
- {
- get
- {
- return instance;
- }
- }
- public GameObject overPanel;
- public GameObject player;
- // Use this for initialization
- void Start()
- {
- instance = this;
- }
- // Update is called once per frame
- void Update()
- {
- }
-
- public void ResetGame()
- {
- SceneManager.LoadScene("main");
- }
- public void GameOver()
- {
- overPanel.SetActive(true);
- Destroy(player);
- }
- }
|