29 for (
movenum_t moveid = 1; moveid <= n_moves; ++moveid) {
36 bSearchScore chldscore(-Quiescence(chldbrd, chldML, -terminalScore, nNewDepth));
58 +
") -- early cut off", terminalScore);
72 bSearchScore bestscore(terminalScore);
74 for (
movenum_t moveid = 1; moveid <= n_moves; ++moveid) {
76 if (m.isNonSilent() || m.isCheck()) {
82 bSearchScore chldscore(-Quiescence(chldbrd, chldML, -nValueAtNullMove, nNewDepth));
84 if (chldscore.improvesOn(bestscore)) {
86 bestscore = chldscore.getScore();
88 if (chldscore.improvesOn(nValueAtNullMove)) {
91 +
") -- cut-off", chldscore.getScore());
92 return chldscore.getScore();
99 return bestscore.getScore();
This is the main include file, needs to be included before any other include.
bScore CalcBestMove(bBoard &b, bMoveList &ml) override
Root search for algorithm.
void setVariation(bBoard const &chldbrd)
boardInfo_t applyMove(bMove const &m) override
modification of board move is kept on previous board newboard does not have move stored and has flag ...
movenum_t generateMoves(bBasicBoard const &b)
generate moves if not yet generated
bool setScoreOfMove(movenum_t const moveid, bScore const score)
Store score of move and update best move.
constexpr movenum_t getNumberOfMoves() const
constexpr movenum_t getNumberOfQSMoves() const
void adjustMaxSearchedDepth(depth_t const nDepth)
void sendInfoCurrMove(bBoard const &b, depth_t const nCurDepth, bMove const &m, movenum_t const moveid) const
bScore RetrieveBoardEvaluation(bBoard &b, gameResult_t const gr=GR_UNSET) const
Get score of board, eventually from cache.
void CheckIfAbortingSearch() const
constexpr bScore realScore() const
constexpr bScore getScore() const
constexpr bScore SCORE_UNDEFINED
std::string to_string(int16_t value)
std::to_string not compatible on Mac OS (Apple LLVM version 5.0) provide generic utility function
#define DEBUG_sendInfoSearching(b, depth, msg, sc)