예제 #1
0
 public void Execute()
 {
     m_room.RemovePlayerUnsafe(m_player);
     //GSPacketIn pkg = m_player.Out.SendUpdateRoomList(m_room);
     //RoomMgr.WaitingRoom.SendToALL(pkg, m_player);
     if (m_room.PlayerCount == 0)
     {
         m_room.Stop();
     }
 }
예제 #2
0
        public void Execute()
        {
            m_room.RemovePlayerUnsafe(m_player);
            //---------------
            BaseRoom[]      list     = RoomMgr.Rooms;
            List <BaseRoom> tempList = new List <BaseRoom>();

            for (int i = 0; i < list.Length; i++)
            {
                if (!list[i].IsEmpty)
                {
                    tempList.Add(list[i]);
                }
            }
            /////
            m_player.Out.SendUpdateRoomList(tempList);
            GSPacketIn pkg = m_player.Out.SendUpdateRoomList(tempList); //m_player.Out.SendUpdateRoomList(m_room);

            RoomMgr.WaitingRoom.SendToALL(pkg, m_player);
            if (m_room.PlayerCount == 0)
            {
                m_room.Stop();
            }
        }