public void LogOff() { if (m_Params != null) { return; } m_Params = true; try { WndManager.Instance.Clear(); } catch { } try { NetServices.Instance.ClearCmdAndHandler(); NetServices.Instance.Disconnect(); } catch { } LogicRuntimeData ld = LogicFlowManager.GetLogic(LogicType.LOGIC_LOGON); ActiveLogic(ld); try { tagReturnLogonEvent pEvent = new tagReturnLogonEvent(); MsgEventHandle.HandleMsg(pEvent); SDKMgr.Instance.Logout(); } catch { } }
public void GlobalInit() { //#if UNITY_EDITOR LogicRuntimeData ld = LogicFlowManager.GetLogic(ResManager.ENABLE_RESOURCES ? LogicType.LOGIC_INIT : LogicType.LOGIC_UPDATE); //#else // LogicRuntimeData ld = LogicFlowManager.GetLogic(LogicType.LOGIC_UPDATE); //#endif ActiveLogic(ld); }
void CheckAction() { if (LogicAction == Action.ACTION_NONE) { return; } if (LogicAction == Action.ACTION_FORWARD) { LogicRuntimeData ld = LogicFlowManager.GetForwardLogic(m_LogicData.Type); if (ld == null) { LogMgr.Log("Logic forward failed."); } ActiveLogic(ld); } else if (LogicAction == Action.ACTION_BACK) { LogicRuntimeData ld = LogicFlowManager.GetBackLogic(m_LogicData.Type); if (ld == null) { LogMgr.Log("Logic back failed."); } ActiveLogic(ld); } else if (LogicAction == Action.ACTION_SHUTDOWN) { SceneMain.Instance.Shutdown(); } else if (LogicAction == Action.ACTION_TOSCENE) { LogicRuntimeData ld = LogicFlowManager.GetLogic(LogicType.LOGIC_SCENE); if (ld == null) { LogMgr.Log("Skip to scene failed."); } ActiveLogic(ld); } LogicAction = Action.ACTION_NONE; }