mirror of
https://github.com/sockspls/badfish
synced 2025-07-11 19:49:14 +00:00
Be sure negative see evasions are at the bottom
Because H.move_ordering_score() can return negative values some negative see moves could be searched before non-negative see moves with negative history. This patch restores proper ordering. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
parent
337ec0f3d0
commit
6fe36d13de
1 changed files with 1 additions and 1 deletions
|
@ -240,7 +240,7 @@ void MovePicker::score_evasions_or_checks() {
|
|||
{
|
||||
m = cur->move;
|
||||
if ((seeScore = pos.see_sign(m)) < 0)
|
||||
cur->score = seeScore;
|
||||
cur->score = seeScore - HistoryMax; // Be sure are at the bottom
|
||||
else if (pos.move_is_capture(m))
|
||||
cur->score = pos.midgame_value_of_piece_on(move_to(m))
|
||||
- pos.type_of_piece_on(move_from(m)) + HistoryMax;
|
||||
|
|
Loading…
Add table
Reference in a new issue