-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathPlayer.h
More file actions
31 lines (27 loc) · 727 Bytes
/
Player.h
File metadata and controls
31 lines (27 loc) · 727 Bytes
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
#ifndef PLAYER_H
#define PLAYER_H
#include "Move.h"
#include "ChessBoard.h"
class Player {
protected:
Move castleMoveCreator(Move move);
private:
bool color;
bool inCheck;
bool hasCastled;
bool isComputer;
ChessBoard *board;
public:
Player(bool color, bool inCheck, bool hasCastled, bool isComputer, ChessBoard *board);
virtual ~Player();
void setInCheck(bool inCheck);
void setHasCastled(bool hasCastled);
ChessBoard *getBoard();
bool getColor();
bool getInCheck();
bool isCheckmate();
bool isStalemate();
bool getHasCastled();
virtual Move handleMove() = 0;
};
#endif