private void OnDestroy() { if (s_instance == this) { s_instance = null; } }
private void Awake() { if (s_instance != null) { Debug.LogError("uMyGUI_PopupManager: there is already an instance of uMyGUI_PopupManager in this scene!"); } s_instance = this; }