/* * A discard stack may be used in order to keep track of the remaining unused cards, otherwise drawn cards return to the bottom of play stack. */ public AbstractPlayingCardsDeck(int numberOfDecks, bool useDiscardStack) { DrawStack = new CardQueue(numberOfDecks); if (useDiscardStack) { DiscardStack = new CardQueue(); UseDiscardStack = useDiscardStack; } Shuffle(1); }
public void GetNewDeck(int numberOfDecks, bool useDiscardStack) { _LastDrawnCard = null; DrawStack = new CardQueue(numberOfDecks); if (useDiscardStack) { DiscardStack = new CardQueue(); UseDiscardStack = useDiscardStack; } }