Example #1
0
 public static void TestWin(ref Deck compDeck)
 {
     // For testing purposes - we just throw away the computers cards until they have 5 left.
     compDeck.ShuffleWinnings();
     while (compDeck.NumCards > 5)
     {
         compDeck.RemoveTopCard();
     }
 }
Example #2
0
 public static bool CheckDeck(ref Deck deck, ref bool playing)
 {
     
     if (deck.NumCards == 0) // If your deck is out of cards
     {
         if (deck.NumWinnings == 0) // If you have no winnings to shuffle back in
         {
             playing = false; // game is over
             return false;
         }
         deck.ShuffleWinnings(); // shuffle your winnings back into your main deck
         return true; // true means we're going to be printing that we shuffled
     }
     return false;
 }