void Awake()
 {
     singleton = this;
 }
 void OnDestroy()
 {
     singleton = null;
 }
Example #3
0
 // Use this for initialization
 void Start()
 {
     if(autoSetup == true){
         gameManager = GameObject.FindGameObjectWithTag("GameController").GetComponent<GameManager1>();
         playerCtrlSetup = GameObject.FindGameObjectWithTag("GameController").GetComponent<PlayerCtrlSetup>();
     }
 }