Esempio n. 1
0
        public bool Contains(Card card, int numberOfCards)
        {
            var cards = TreasureSupply.Select(x => x.Cards)
                        .Concat(VictorySupply.Select(x => x.Cards))
                        .Concat(KingdomSupply.Select(x => x.Cards));

            return(cards.Select(x => x.FirstOrDefault())
                   .Count(x => x == card) >= numberOfCards);
        }
Esempio n. 2
0
        //TODO: needs to be modified
        //TODO: implement ruins pile
        public bool Contains(Card card)
        {
            var cards = TreasureSupply.Select(x => x.Cards)
                        .Concat(VictorySupply.Select(x => x.Cards))
                        .Concat(KingdomSupply.Select(x => x.Cards));

            return(cards.Select(x => x.FirstOrDefault())
                   .Contains(card));
        }