Consider only pawns as CTF path blockers
authorFabian Fichter <ianfab@users.noreply.github.com>
Sat, 9 May 2020 08:29:05 +0000 (10:29 +0200)
committerFabian Fichter <ianfab@users.noreply.github.com>
Sat, 9 May 2020 08:29:05 +0000 (10:29 +0200)
kingofthehill STC
LLR: 2.97 (-2.94,2.94) [0.00,10.00]
Total: 860 W: 418 L: 316 D: 126
http://www.variantfishtest.org:6543/tests/view/5eb10e4e6e23db36d55f2aa6

kingofthehill LTC
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 1112 W: 525 L: 420 D: 167
http://www.variantfishtest.org:6543/tests/view/5eb171106e23db36d55f2ab4

racingkings STC
LLR: 2.95 (-2.94,2.94) [-10.00,5.00]
Total: 1942 W: 635 L: 597 D: 710
http://www.variantfishtest.org:6543/tests/view/5eb1303d6e23db36d55f2aac

racingkings LTC
LLR: 2.95 (-2.94,2.94) [-10.00,5.00]
Total: 8208 W: 2257 L: 2257 D: 3694
http://www.variantfishtest.org:6543/tests/view/5eb1bdae6e23db36d55f2ab7

src/evaluate.cpp

index d8de620..1f9a485 100644 (file)
@@ -932,7 +932,7 @@ namespace {
                 Square s = pop_lsb(&current);
                 Bitboard attacks = (  (PseudoAttacks[Us][ptCtf][s] & pos.pieces())
                                     | (PseudoMoves[Us][ptCtf][s] & ~pos.pieces())) & ~processed & pos.board_bb();
-                ctfPieces |= attacks & ~pos.pieces(Us) & ~attackedBy[Them][ALL_PIECES];
+                ctfPieces |= attacks & ~(pos.pieces(Us, PAWN) | attackedBy[Them][ALL_PIECES]);
                 onHold |= attacks & ~((pos.pieces(Us, PAWN) & attackedBy[Them][ALL_PIECES]) | attackedBy2[Them]);
                 onHold2 |= attacks;
             }