コード例 #1
0
        protected override void OnClosed(HallServerSession session, string cause, bool isInternalCause)
        {
            heartCheckTimer.Remove(session);

            var netMessage = new NetMessage(2, session, "", cause, isInternalCause);
            var worker     = Program.workerMgr.AllotWorker(session.sessionID);

            worker.PushNetMessage(netMessage);
        }
コード例 #2
0
        protected override void OnClosed(GameServerSession session, string cause, bool isInternalCause)
        {
            heartCheckTimer.Remove(session);

            var netMessage = new NetMessage(2, session, "", cause, isInternalCause);

            //桌子分多线处理
            Worker worker = null;

            if (session.TableId > 0)
            {
                worker = Program.workerMgr.AllotWorker(session.TableId, false);
            }
            else
            {
                worker = Program.workerMgr.AllotWorker(session.sessionID, true);
            }

            worker.PushNetMessage(netMessage);
        }