mirror of
https://github.com/opelly27/Stockfish.git
synced 2026-05-20 10:57:43 +00:00
Fix stalemate value in MCTS (#4015)
This commit is contained in:
+1
-1
@@ -2795,7 +2795,7 @@ namespace Search
|
|||||||
Value terminal_value(Position& pos) const {
|
Value terminal_value(Position& pos) const {
|
||||||
|
|
||||||
if (MoveList<LEGAL>(pos).size() == 0)
|
if (MoveList<LEGAL>(pos).size() == 0)
|
||||||
return pos.checkers() ? VALUE_MATE : -VALUE_MATE;;
|
return pos.checkers() ? VALUE_MATE : VALUE_DRAW;
|
||||||
|
|
||||||
if (ply >= MAX_PLY - 2 || pos.is_draw(ply - 1))
|
if (ply >= MAX_PLY - 2 || pos.is_draw(ply - 1))
|
||||||
return VALUE_DRAW;
|
return VALUE_DRAW;
|
||||||
|
|||||||
Reference in New Issue
Block a user