public static void DestroyAll() { foreach (var model in _uiModels) { model.Destory(); } _uiModels.Clear(); _uiModelsDic.Clear(); UiCreateFactory.Destroy(); UiCommon.UIManager.Destroy(); }
public void OnLoadResources(IUnityAssetManager assetManager) { if (!_loading) { CreateUIComponent(_contexts); InitLoxodon(); InitUiGlobalData(_contexts); UiCreateFactory.Initialize(_contexts, OnModelInitialized); UiCreateFactory.RegisterAllUi(_contexts); _uiCount = UiCreateFactory.AddCreateUI(_contexts.session.clientSessionObjects.GameRule); UiCreateFactory.CreateUi(OnModelLoaded); InitPlayerData(); CheckExit(); _loading = true; SingletonManager.Get <SubProgressBlackBoard>().Add((uint)_uiCount); } }