|
@@ -31,10 +31,9 @@ struct chessy::MoveInfo
|
|
|
|
|
|
//! if the move is an en-passant move, this field holds the square of
|
|
|
//! the pawn, that was captured. Otherwise this index should be zero.
|
|
|
- Index enPassantTarget;
|
|
|
+ //Index enPassantTarget;
|
|
|
|
|
|
- inline MoveInfo(void) :
|
|
|
- enPassantTarget{ 0 } {}
|
|
|
+ MoveInfo(void) = default;
|
|
|
|
|
|
MoveInfo(Move move, const ChessGame& cg);
|
|
|
};
|
|
@@ -78,6 +77,8 @@ class chessy::ChessGame
|
|
|
//! holds the zobrist hash value for the current position
|
|
|
HashValue hash;
|
|
|
|
|
|
+ std::vector<HashValue> history;
|
|
|
+
|
|
|
public:
|
|
|
|
|
|
ChessGame(void);
|
|
@@ -112,6 +113,9 @@ public:
|
|
|
|
|
|
inline int getCastlingRights(void) const { return castlingRights; }
|
|
|
|
|
|
+ inline HashValue getHash(void) const { return hash; }
|
|
|
+ inline const std::vector<HashValue>& getHistory(void) const { return history; }
|
|
|
+
|
|
|
void move(Move move);
|
|
|
inline Side getTurn(void) const { return turn; }
|
|
|
|