-
Notifications
You must be signed in to change notification settings - Fork 0
/
Stock.h
46 lines (41 loc) · 1.08 KB
/
Stock.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
35
36
37
38
39
40
41
42
43
44
45
46
//
// Created by EMRE on 11/20/2020.
//
#ifndef ASSIGNMENT1_STOCK_H
#define ASSIGNMENT1_STOCK_H
#include "Pile.h"
#include <iostream>
using namespace std;
class StockCard {
public:
string cardName = "";
bool ifExist = false;
};
class Stock {
public:
int stockSize;
int subStockSize;
int wasteSize;
int moveNum;
int initialWasteSize;
int openedCards;
StockCard stock[24];
StockCard subStock[24];
StockCard waste[3];
void createStock(string* cards);
bool openStock();
void refreshStock();
void restoreWaste();
void removeCard();
bool checkStock();
bool checkAllOpened();
void printStock(ofstream* output);
bool moveWaste(int pileNum, Pile* pile);
bool moveToFoundation(Foundation* foundation);
void resetWaste();
bool checkWaste();
void printWaste(ofstream* output);
void openPrevious();
void removeWaste();
};
#endif //ASSIGNMENT1_STOCK_H