Пример #1
0
 public void UpdateClients(Proposal p, string cancelledPlayer)
 {
     foreach (string name in p.PlayerNames)
     {
         List<Proposal> proposals = GetProposalsForPlayer(name);
         Clients["LOBBY_"+name].updateProposals(proposals);
     }
     if (cancelledPlayer != null)
     {
         List<Proposal> proposals = GetProposalsForPlayer(cancelledPlayer);
         Clients["LOBBY_"+cancelledPlayer].updateProposals(proposals);
     }
 }
Пример #2
0
 public void NewProposal(string hostPlayer, List<string> opponents, int versionId, string gameName)
 {
     Proposal p = new Proposal(hostPlayer, opponents, gameName, versionId);
     activeProposals.Add(p);
     UpdateClients(p,null);
     return;
 }