Skip to content

Commit

Permalink
Don't perform alpha update when staticEval > alpha also when in check
Browse files Browse the repository at this point in the history
  • Loading branch information
eduherminio committed Jan 18, 2025
1 parent 240eb52 commit 8db820d
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/Lynx/Search/NegaMax.cs
Original file line number Diff line number Diff line change
Expand Up @@ -588,12 +588,12 @@ public int QuiescenceSearch(int ply, int alpha, int beta, CancellationToken canc
PrintMessage(ply - 1, "Pruning before starting quiescence search");
return eval;
}
}

// Better move
if (eval > alpha)
{
alpha = eval;
// Better move
if (eval > alpha)
{
alpha = eval;
}
}

Span<Move> moves = stackalloc Move[Constants.MaxNumberOfPossibleMovesInAPosition];
Expand Down

0 comments on commit 8db820d

Please sign in to comment.