/// <summary> /// 开始匹配的处理 /// </summary> /// <param name="client"></param> /// <param name="isSingle"></param> /// <param name="playerID"></param> private void OnMatchStart(MOBAClient client, int playerID) { //非法操作检测 if (playerCache.GetID(client) != playerID) { return; } MatchRoom room = matchCache.EnterMatch(client, playerID); Send(client, OperationCode.PlayerCode, OpPlayer.MatchStart, 0, "开始匹配成功"); //如果房间满了,就开始选人 if (room.RoomIsFull()) { //通知房间内所有人进入选人界面 room.Broadcast(OperationCode.PlayerCode, OpPlayer.MatchComplete, 1, "是否进入选人界面(10秒)", null); StartSelectAction(room.RedTeamIdList, room.BlueTeamIdList); //删除房间 matchCache.DeleteRoom(room); } }