-
Notifications
You must be signed in to change notification settings - Fork 0
/
Board.h
49 lines (44 loc) · 1.14 KB
/
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
48
49
#ifndef p1_remake_Board_h
#define p1_remake_Board_h
#include "Piece.h"
#include <cstdlib>
#include <vector>
#include <string>
typedef uint64_t Bitboard;
class Board
{
public:
Board(){};
Board(const Board&);
void addPiece(Piece p) { pieces.push_back(p); }
Piece copyPiece(int) const;
Piece* refByPosition(int);
std::vector<Piece *> getPieces(int);
int numPieces() const;
bool move(Piece*,int);
void debugListPieces();
void setMoveName(std::string s) { moveName = s; }
std::string getMoveName() const { return moveName; }
std::string displayBoardPieces();
std::string getChessPosition(TYPE,int,int);
Piece* findPiece(int,TYPE);
void printBoard();
private:
std::string moveName;
bool deleteEnemyAtPosition(Piece);
bool checkNoFriendlies(Piece, int);
std::vector<Piece> pieces;
};
#endif
/*
getters and setters
add a piece by type, player and location
get a piece by location
get a piece by player
get all pieces by player
boards
construct a Bitboard with a single piece on it
construct a Bitboard with all pieces
construct a Bitboard with all pieces by one player on it
construct a board with a possible move (logic not here)
*/