Exemplo n.º 1
0
Arquivo: Game.cs Projeto: djericj/Uno
        private void ReloadFromDiscard()
        {
            Object obj = new Object();

            lock (obj)
            {
                Card[] discardCards = new Card[Discard.Count()];
                Discard.CopyTo(discardCards, 0);
                foreach (var card in discardCards)
                {
                    GameDeck.Enqueue(card);
                }
                Discard.Clear();
            }
        }
Exemplo n.º 2
0
        public void ResetState()
        {
            ActionsAvailable = 0;

            AllCards.Clear();
            Deck.Clear();
            Discard.Clear();
            Hand.Clear();
            Characters.Clear();
            Lessons.Clear();
            Creatures.Clear();
            Location.Clear();
            Match.Clear();
            Items.Clear();
            Adventure.Clear();
        }
Exemplo n.º 3
0
 /// <summary>
 /// init hand
 /// </summary>
 public void InitHand()
 {
     Hand.Clear();
     Discard.Clear();
     HandRank = new Rank();
 }