mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-20 09:06:45 +08:00
Fix a small bug in rook pawn evaluation
Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
@@ -1018,8 +1018,8 @@ namespace {
|
|||||||
// value if the other side has a rook or queen.
|
// value if the other side has a rook or queen.
|
||||||
if (square_file(s) == FILE_A || square_file(s) == FILE_H)
|
if (square_file(s) == FILE_A || square_file(s) == FILE_H)
|
||||||
{
|
{
|
||||||
if( pos.non_pawn_material(them) == KnightValueMidgame // FIXME should be <= ???
|
if( pos.non_pawn_material(them) <= KnightValueMidgame
|
||||||
&& pos.piece_count(them, KNIGHT) == 1)
|
&& pos.piece_count(them, KNIGHT) <= 1)
|
||||||
ebonus += ebonus / 4;
|
ebonus += ebonus / 4;
|
||||||
else if(pos.rooks_and_queens(them))
|
else if(pos.rooks_and_queens(them))
|
||||||
ebonus -= ebonus / 4;
|
ebonus -= ebonus / 4;
|
||||||
|
|||||||
Reference in New Issue
Block a user