void Awake() { if (m_instance == null) { m_instance = this; } else if (m_instance != this) { Destroy(gameObject); } DontDestroyOnLoad(gameObject); }
void Awake() { if (m_instance == null) { m_instance = this; } else if (m_instance != this) Destroy(gameObject); DontDestroyOnLoad(gameObject); }