void OnOpen(CUILoadState uiState, params object[] args) { if (OpenWindowEvent != null) { OpenWindowEvent(uiState.UIType); } CUIController uiBase = uiState.UIWindow; uiBase.OnPreOpen(); if (uiBase.gameObject.activeSelf) { uiBase.OnClose(); } else { uiBase.gameObject.SetActive(true); } uiBase.OnOpen(args); }