mirror of
https://github.com/sockspls/badfish
synced 2025-07-11 19:49:14 +00:00
Include file attacks in 'major on pawn'
Passed both short TC: LLR: 2.97 (-2.94,2.94) Total: 57846 W: 12248 L: 11974 D: 33624 And long one: LLR: 2.95 (-2.94,2.94) Total: 9181 W: 1732 L: 1581 D: 5868 bench: 4609948
This commit is contained in:
parent
e05c80a088
commit
e95e69515a
1 changed files with 2 additions and 2 deletions
|
@ -541,8 +541,8 @@ Value do_evaluate(const Position& pos, Value& margin) {
|
|||
&& relative_rank(Us, pos.king_square(Them)) == RANK_8)
|
||||
score += Piece == ROOK ? RookOn7th : QueenOn7th;
|
||||
|
||||
// Major piece attacking enemy pawns on the same rank
|
||||
Bitboard pawns = pos.pieces(Them, PAWN) & rank_bb(s);
|
||||
// Major piece attacking enemy pawns on the same rank/file
|
||||
Bitboard pawns = pos.pieces(Them, PAWN) & PseudoAttacks[ROOK][s];
|
||||
if (pawns)
|
||||
score += popcount<Max15>(pawns) * (Piece == ROOK ? RookOnPawn : QueenOnPawn);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue