void Awake() { if (_instance == null) { _instance = this; DontDestroyOnLoad(this.gameObject); SetUpSkillTree(); } else { Destroy(this.gameObject); } }
void Awake() { if (instance == null) { instance = this; DontDestroyOnLoad(gameObject); } else if (instance != this) { Debug.Log("Mauvaise instance"); Destroy(gameObject); } SetUpSkillTree(); }