diff --git a/include/BitBoard.h b/include/BitBoard.h index 7f8f290..3d1ffbf 100644 --- a/include/BitBoard.h +++ b/include/BitBoard.h @@ -89,6 +89,7 @@ class BitBoard vmup actions() const; bup result(mup &move) const; void printState() const; + std::string toString() const; }; #endif diff --git a/include/MinimaxSearch.h b/include/MinimaxSearch.h index b40af94..b92ffec 100644 --- a/include/MinimaxSearch.h +++ b/include/MinimaxSearch.h @@ -13,7 +13,7 @@ typedef std::unique_ptr mup; class MinimaxSearch { private: - static const int MIN_DEPTH = 3; + static const int MIN_DEPTH = 5; static const int MAX_DEPTH = 9; Heuristic heuristic; diff --git a/src/BitBoard.cpp b/src/BitBoard.cpp index 07316ab..ec78925 100644 --- a/src/BitBoard.cpp +++ b/src/BitBoard.cpp @@ -125,18 +125,32 @@ BitBoard BitBoard::boardMove(BitBoard &board, uint32_t piece, uint32_t moveTo) c int diff = std::abs((double)pieceLoc - moveLoc); int avg = ((pieceLoc + moveLoc) / 2); if (board.m_isBlacksTurn) { - if (diff == 2 || diff == 14) white &= ~(1<= MAX_DEPTH) return true; bool jumpAvailable = heuristic.jumpeablePieces() != 0;