X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fendgame.cpp;h=b64b75cbca63e22a0f375611d9e5e4be920ea864;hp=d38247805b50fe87ec6df57cf3cd34b7982e61af;hb=69eb391cd779223c331fb0de80392cbd323055a9;hpb=d8f683760c9eb6d2c4714ec83e717dd2143de55c diff --git a/src/endgame.cpp b/src/endgame.cpp index d3824780..b64b75cb 100644 --- a/src/endgame.cpp +++ b/src/endgame.cpp @@ -110,14 +110,6 @@ Endgames::Endgames() { } -template -void Endgames::add(const string& code) { - StateInfo st; - map()[Position().set(code, WHITE, &st).material_key()] = std::unique_ptr>(new Endgame(WHITE)); - map()[Position().set(code, BLACK, &st).material_key()] = std::unique_ptr>(new Endgame(BLACK)); -} - - /// Mate with KX vs K. This function is used to evaluate positions with /// king and plenty of material vs a lone king. It simply gives the /// attacking side a bonus for driving the defending king towards the edge @@ -652,7 +644,7 @@ ScaleFactor Endgame::operator()(const Position& pos) const { if (relative_rank(strongSide, pawnSq) <= RANK_5) return SCALE_FACTOR_DRAW; - + Bitboard path = forward_bb(strongSide, pawnSq); if (path & pos.pieces(weakSide, KING))