Idea originated from a post of Don Dailey
on talkchess and reported by Eelco.
This is the last succesful attempt of a long
series of trials (as usually happens, the
'idea' alone is not enough).
Passed both short 15secs TC
LLR: 2.97 (-2.94,2.94)
Total: 7629 W: 1645 L: 1515 D: 4469
And long 60secs TC
LLR: 2.96 (-2.94,2.94)
Total: 10218 W: 1932 L: 1775 D: 6511
bench:
4944581
if (Piece == BISHOP)
score -= BishopPawns * ei.pi->pawns_on_same_color_squares(Us, s);
if (Piece == BISHOP)
score -= BishopPawns * ei.pi->pawns_on_same_color_squares(Us, s);
- // Bishop and knight outposts squares
- if ( (Piece == BISHOP || Piece == KNIGHT)
- && !(pos.pieces(Them, PAWN) & pawn_attack_span(Us, s)))
- score += evaluate_outposts<Piece, Us>(pos, ei, s);
+ if (Piece == BISHOP || Piece == KNIGHT)
+ {
+ // Bishop and knight outposts squares
+ if (!(pos.pieces(Them, PAWN) & pawn_attack_span(Us, s)))
+ score += evaluate_outposts<Piece, Us>(pos, ei, s);
+
+ // Pawn in front of knight/bishop
+ if ( relative_rank(Us, s) < RANK_5
+ && (pos.pieces(PAWN) & (s + pawn_push(Us))))
+ score += make_score(16, 0);
+ }
if ( (Piece == ROOK || Piece == QUEEN)
&& relative_rank(Us, s) >= RANK_5)
if ( (Piece == ROOK || Piece == QUEEN)
&& relative_rank(Us, s) >= RANK_5)