//public Texture2D guiBackground; //bool gameOver = false; public static PointManagement GetInstance() { if (instance == null) { GameObject go = new GameObject("GameManager"); go.AddComponent<PointManagement>(); instance = go.GetComponent<PointManagement>(); } return instance; }
void Awake() { if (instance != null) { Debug.Log ("Wrong"); Destroy (gameObject); return; } instance = this; if (Input.GetKey (KeyCode.Escape)) Application.Quit (); }