/// <summary> /// 进入房间 /// </summary> /// <param name="userId">用户id</param> public void Enter(int userId, ClientPeer client) { UIdClientDict.Add(userId, client); MultiPlayerDto mpdto = new MultiPlayerDto(userId); for (int i = 0; i < 4; i++) { if (PlayerList[i] == null) { mpdto.position = i + 1; PlayerList[i] = mpdto; UIdPositionDict.Add(userId, i + 1); break; } } }
/// <summary> /// 进入房间 /// </summary> /// <param name="userId"></param> public void Enter(int userId, ClientPeer client) { UIdClientDict.Add(userId, client); }
/// <summary> /// 开始战斗 /// </summary> public void StartFight(int userId, ClientPeer client) { UIdClientDict.Add(userId, client); }