Exemplo n.º 1
0
 void Start()
 {
     if (m_INSTANCE != null && m_INSTANCE != this)
     {
         Destroy(this.gameObject);
         return;
     }
     else
     {
         m_INSTANCE = this;
     }
     DontDestroyOnLoad(gameObject);
 }
Exemplo n.º 2
0
 void Start()
 {
     if (m_INSTANCE != null && m_INSTANCE != this)
     {
         Destroy(this.gameObject);
         return;
     }
     else
     {
         m_INSTANCE = this;
     }
     DontDestroyOnLoad(gameObject);
 }