Lines Matching refs:pile
317 // Redraw the m_pack, discard pile, the bases and the foundations
352 // Returns pointer to the pile, or 0 if (x, y) is not over a pile
353 // or the pile is empty
440 Pile* pile = WhichPile(x, y);
441 if (!pile) return;
444 if (pile == m_pack)
450 Card* card = pile->GetTopCard();
466 m_foundations[i + 4] != pile &&
469 pile->RemoveTopCard(dc);
471 DoMove(dc, pile, m_foundations[i + 4]);
481 if (m_foundations[i]->AcceptCard(card) && m_foundations[i] != pile)
483 pile->RemoveTopCard(dc);
485 DoMove(dc, pile, m_foundations[i]);
493 m_bases[i] != pile &&
496 pile->RemoveTopCard(dc);
498 DoMove(dc, pile, m_bases[i]);
505 if (m_bases[i]->AcceptCard(card) && m_bases[i] != pile)
507 pile->RemoveTopCard(dc);
509 DoMove(dc, pile, m_bases[i]);
539 Pile* pile = WhichPile(x, y);
540 if (pile && pile != m_pack)
542 Card* card = pile->GetTopCard();
549 if (m_foundations[i]->AcceptCard(card) && m_foundations[i] != pile)
558 m_bases[i] != pile)
570 // Scan the piles to see if this card overlaps a pile and can be added
571 // to the pile. If the card overlaps more than one pile on which it can be placed
572 // then put it on the nearest pile.
584 // find the nearest pile which will accept the card
618 // Add to new pile
627 // Return card to src pile
638 bool Game::DropCard(int x, int y, Pile* pile, Card* card)
641 if (pile->Overlap(x, y))
643 if (pile->AcceptCard(card))
831 // The Base class: holds the initial pile of four cards //
853 // pile is empty - ACCEPT
882 // It's an ace and the pile is empty - ACCEPT