예제 #1
0
 public void Copy(DeckCollection collection, List<SuitEnum> availableSuits)
 {
     _decks.Clear();
     BackDeck = collection.BackDeck;
     _decks.Add(BackDeck.Name, BackDeck);
     WarehouseDeck = collection.WarehouseDeck;
     _decks.Add(WarehouseDeck.Name, WarehouseDeck);
     BorderChestDecks = collection.BorderChestDecks;
     for (int i = 0; i < BorderCount; i++)
     {
         _decks.Add(BorderChestDecks[i].Name, BorderChestDecks[i]);
     }
     MiddleChestDecks = collection.MiddleChestDecks;
     for (int i = 0; i < MiddleCount; i++)
     {
         _decks.Add(MiddleChestDecks[i].Name, MiddleChestDecks[i]);
     }
     ResultDecks = collection.ResultDecks;
     for (int i = 0; i < ResultCount; i++)
     {
         ResultDecks[i].AvailableSuits = availableSuits;
         _decks.Add(ResultDecks[i].Name, ResultDecks[i]);
     }
     TopDecks = collection.TopDecks;
     for (int i = 0; i < TopCount; i++)
     {
         _decks.Add(TopDecks[i].Name, TopDecks[i]);
     }
 }
예제 #2
0
파일: Game.cs 프로젝트: vitaliygor/Well
 public Game()
 {
     _options = new OptionsViewModel();
     _options.Language = _options.Language;
     _availableSuits = new List<SuitEnum>(_suits);
     _collection = new DeckCollection(_availableSuits);
     _generalDeck = new List<Card>();
     _steps = new List<Step>();
 }
예제 #3
0
 public DeckEnumerator(DeckCollection coll)
 {
     _enumerator = coll.GetDictonaryEnumerator();
 }