Beispiel #1
0
        public void addPlayer()
        {
            ClsHandCard a = new ClsHandCard();

            arrPlayers.Add(a);
            numOfPlayers++;
        }
Beispiel #2
0
 public bool play(ClsHandCard Player, List <ClsCard> SelectedCard)
 {
     if (ClsRules.IsWin(JustPlayCard, SelectedCard) || (JustPlayer == -1 && ClsRules.isTrue(SelectedCard)))
     {
         foreach (ClsCard i in SelectedCard)
         {
             Player.getarrCards().RemoveAll(a => a.value == i.value && a.character == i.character);
         }
         Player.setnumOfCard(Player.getnumOfCard() - SelectedCard.Count);
         if (Player.getnumOfCard() == 0)
         {
             Player.setAct(false);
             CountOf0++;
             Player.setRank(CountOf0);
         }
         if (Player.getnumOfCard() == 0 && CountOf0 == 1)
         {
             rank1 = playing;
         }
         JustPlayer   = playing;
         JustPlayCard = SelectedCard;
         return(true);
     }
     return(false);
 }
Beispiel #3
0
 public void ignore(ClsHandCard Player)
 {
     Player.setAct(false);
 }