-
Notifications
You must be signed in to change notification settings - Fork 0
/
Board.h
48 lines (36 loc) · 856 Bytes
/
Board.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
47
#pragma once
#include "Const.h"
#include "GameObject.h"
#include "Error.h"
#include <algorithm>
class Board
{
char board[terminal_Size_X][terminal_Size_Y];
int BoardRows; // Log size of Board
int BoardCols;
GameObject legendPos;
vector<GameObject> ghostsStartPos;
int ghostNum;
GameObject playerStartPos;
vector<GameObject> SecretPathWays;
int maxFood = 0;
void ClearLegendArea();
public:
Board(string fileName);
Board();
void printBoard();
// GETTERS:
char** getBoard();
char getChar(int i, int j);
int getBoardRows();
int getBoardCols();
GameObject getLegendPos();
vector<GameObject> getGhostsStartPos();
int getGhostNum();
GameObject getPlayerStartPos();
vector<GameObject> getSecretPathWays();
int getMaxFood();
bool checkBlankSpaceForTunnel(int i, int j);
// SETTER:
void setBoard(GameObject pos, char ch);
};