protected void OnDestroy() { if (singleton == this) { singleton = null; } }
protected void Awake() { if (singleton == null) { singleton = this; DontDestroyOnLoad(singleton); init(); subscribeToEvents(); } else { Destroy(this); } }