/// <summary> /// 账号登出 /// </summary> private void OnLogoutAccount(PacketBase packet) { Log.Debug("登出数量1:" + ++loginout_count); gs2ss.LogoutAccount msg = packet as gs2ss.LogoutAccount; HandleLogoutAccount(msg.client_uid); UnitManager.Instance.RemoveSession(msg.client_uid); }
/// <summary> /// 主动登出,或异常退出 /// </summary> public void Logout() { if (m_session_status == eSessionStatus.LOGOUTING) { return; } m_session_status = eSessionStatus.LOGOUTING; //发送到ss,登出 if (m_account_idx > 0) { gs2ss.LogoutAccount ss_msg = PacketPools.Get(gs2ss.msg.LOGOUT_ACCOUNT) as gs2ss.LogoutAccount; ss_msg.account_idx = m_account_idx; this.Send2SS(ss_msg); } }
/// <summary> /// 主动登出,或异常退出 /// </summary> public void Logout() { if (m_session_status == eSessionStatus.LOGOUTING) { return; } m_session_status = eSessionStatus.LOGOUTING; Log.Debug("登出数量:" + ++loginout_count); //发送到ss,登出 if (m_account_idx > 0) { gs2ss.LogoutAccount ss_msg = PacketPools.Get(gs2ss.msg.LOGOUT_ACCOUNT) as gs2ss.LogoutAccount; ss_msg.client_uid = m_client_uid; ss_msg.account_idx = m_account_idx; this.Send2SS(ss_msg); } }
/// <summary> /// 账号登出 /// </summary> private void OnLogoutAccount(PacketBase packet) { gs2ss.LogoutAccount msg = packet as gs2ss.LogoutAccount; HandleLogoutAccount(msg.account_idx); }