Exemplo n.º 1
0
 private void Awake()
 {
     if (instance != null && instance != this)
     {
         Destroy(gameObject);
     }
     else
     {
         instance = this;
         DontDestroyOnLoad(gameObject);
     }
 }
Exemplo n.º 2
0
 void Start()
 {
     stManager = GameObject.FindGameObjectWithTag("SceneManager").GetComponent <SceneTransition_Manager>();
 }