Ejemplo n.º 1
0
 /// <summary>
 /// 为玩家创建房间,开启游戏,并为玩家分配座位。默认uid都是不相等的。
 /// </summary>
 /// <param name="uids">玩家的UID表</param>
 /// <param name="mode">游戏模式</param>
 public Room(ulong[] uids, GameMode mode = GameMode.SiAn)
 {
     ID          = Counter;
     Channel     = new Channel(uids);
     Gamemanager = new GameManager(mode);
     Gamemanager.StartUp();
     PlayersInfo = new List <PlayerInfo>(4);
     foreach (var uid in uids)
     {
         PlayersInfo.Add(new PlayerInfo(uid, Gamemanager.Enter()));
     }
 }