Exemplo n.º 1
0
 public Tableau(deck deck, int x, int y, int width)
 {
     cascades = new LinkedList <Cascade>();
     for (int i = 0; i < 4; i++)
     {
         cascades.AddLast(new Cascade(7, x + i * width / 8, y, deck));
     }
     for (int i = 4; i < 8; i++)
     {
         cascades.AddLast(new Cascade(6, x + i * width / 8, y, deck));
     }
 }
Exemplo n.º 2
0
 public Cascade(int numberOfInitialCards, int x, int y, deck deck)
 {
     cards = new LinkedList <Card>();
     for (int i = 0; i < numberOfInitialCards; ++i)
     {
         Card card = deck.Top();
         card.X = x;
         card.Y = y + i * DeltaCardY;
         cards.AddLast(deck.Top());
         deck.Pop();
     }
     this.x = x;
     this.y = y;
 }