Ejemplo n.º 1
0
        static void TestBadDeck()
        {
            GameAnalyzer gameAnalyzer = new GameAnalyzer();

            gameAnalyzer.OnGameStart();
            gameAnalyzer.OnOpponentPlayCard(new Hearthstone_Deck_Tracker.Hearthstone.Card(HearthDb.Cards.Collectible[HearthDb.CardIds.Collectible.Druid.AddledGrizzly]));
            gameAnalyzer.OnOpponentPlayCard(new Hearthstone_Deck_Tracker.Hearthstone.Card(HearthDb.Cards.Collectible[HearthDb.CardIds.Collectible.Mage.Aluneth]));
            gameAnalyzer.OnGameEnd();
        }
Ejemplo n.º 2
0
        static void TestDeck()
        {
            HearthDb.Deckstrings.Deck deck = HearthDb.Deckstrings.DeckSerializer.Deserialize("AAECAf0ECvsMoM4Cws4Cm9MCnOICo+sCpvACt/ECw/gCxvgCCk3JA+wHm8IC08UClscCm8sC1+ECluQC4vgCAA==");
            GameAnalyzer gameAnalyzer      = new GameAnalyzer();
            var          pEnum             = deck.GetCards().GetEnumerator();
            Dictionary <Hearthstone_Deck_Tracker.Hearthstone.Card, int> FindDeck = new Dictionary <Hearthstone_Deck_Tracker.Hearthstone.Card, int>();

            gameAnalyzer.OnGameStart();
            for (int i = 0; pEnum.MoveNext(); i++)
            {
                for (int cardNo = 0; cardNo < pEnum.Current.Value; cardNo++)
                {
                    gameAnalyzer.OnOpponentPlayCard(new Hearthstone_Deck_Tracker.Hearthstone.Card(pEnum.Current.Key));
                }
                gameAnalyzer.GetBestDeck().CopyToDict(FindDeck, true);
                if (i > 10)
                {
                    break;
                }
            }
            gameAnalyzer.OnGameEnd();
            //gameAnalyzer.OnOpponentPlayCard(new Hearthstone_Deck_Tracker.Hearthstone.Card(HearthDb.Cards.Collectible[HearthDb.CardIds.Collectible.Druid.AddledGrizzly]));
            //FindDeck = gameAnalyzer.GetBestDeck();
        }