protected override void OnCardPicked(Card card)
        {
            if (cardMemory.Contains(card)) return;

            if (cardMemory.Count() > 6)
            {
                cardMemory.RemoveAt(random.Next(0, cardMemory.Count));
            }

            cardMemory.Add(card);
        }
Exemplo n.º 2
0
        protected List<Card> CreateCards()
        {
            List<Card> cards = new List<Card>();

            BitmapImage backgroundImage = GetImage("images/napkin.png");

            for(int x = 1; x < 19; x++)
            {
                BitmapImage frontImage = GetImage(String.Format("images/{1}/R{0}.png", x, iconSet));
                Card a = new Card(x.ToString(), frontImage, backgroundImage);

                frontImage = GetImage(String.Format("images/{1}/R{0}.png", x, iconSet));
                Card b = new Card(x.ToString(), frontImage, backgroundImage);

                cards.Add(a);
                cards.Add(b);
            }
            return cards;
        }
Exemplo n.º 3
0
        protected virtual void OnCardPicked(Card card)
        {

        }