mirror of
https://github.com/sockspls/badfish
synced 2025-07-11 19:49:14 +00:00
Contempt factor: use DrawValue also in case of stealmates
Spotted by Jörg Oster. No functional change (when contempt factor is not used).
This commit is contained in:
parent
1018474853
commit
55bd27b8f0
1 changed files with 2 additions and 1 deletions
|
@ -1023,7 +1023,8 @@ split_point_start: // At split points actual search starts from here
|
||||||
// If we are in a singular extension search then return a fail low score.
|
// If we are in a singular extension search then return a fail low score.
|
||||||
// A split node has at least one move, the one tried before to be splitted.
|
// A split node has at least one move, the one tried before to be splitted.
|
||||||
if (!moveCount)
|
if (!moveCount)
|
||||||
return excludedMove ? alpha : inCheck ? mated_in(ss->ply) : VALUE_DRAW;
|
return excludedMove ? alpha
|
||||||
|
: inCheck ? mated_in(ss->ply) : DrawValue[pos.side_to_move()];
|
||||||
|
|
||||||
// If we have pruned all the moves without searching return a fail-low score
|
// If we have pruned all the moves without searching return a fail-low score
|
||||||
if (bestValue == -VALUE_INFINITE)
|
if (bestValue == -VALUE_INFINITE)
|
||||||
|
|
Loading…
Add table
Reference in a new issue