-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDeck.h
34 lines (30 loc) · 820 Bytes
/
Deck.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
//These protect the header files.
#ifndef DECK_H
#define DECK
//George Vargas
//CECS 282-07
//Prog 1-Solitaire Prime
//Feb 12, 2020
#include "Card.h"
using namespace std;
class Deck
{
//This creates the array for the deck of cards.
private:
Card pile[52];
int topCard = 0;
public:
//constructor which creates a deck of 52 cards. Ace of Spades on top, followed by the rest of the Spades in order, followed by Hearts, Diamonds and Clubs.
Deck();
//Reset the deck so it looks like a new deck.
void refreshDeck();
//Deal a card from the top of the deck.
Card deal();
//Shuffle the cards in the deck.
void shuffle();
//Show all the cards in the deck: 13 columns and 4 rows.
void showDeck();
//Return the number of cards left in the deck.
int cardsLeft();
};
#endif