Tweak connected bonus for drop variants
authorFabian Fichter <ianfab@users.noreply.github.com>
Fri, 24 May 2019 17:40:26 +0000 (19:40 +0200)
committerFabian Fichter <ianfab@users.noreply.github.com>
Mon, 27 May 2019 20:04:41 +0000 (22:04 +0200)
crazyhouse STC
LLR: 2.95 (-2.94,2.94) [0.00,10.00]
Total: 5584 W: 2806 L: 2626 D: 152
http://35.161.250.236:6543/tests/view/5ce82ccd6e23db34f4206b26

crazyhouse LTC
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 2588 W: 1324 L: 1187 D: 77
http://35.161.250.236:6543/tests/view/5ceac7766e23db34f4206b3d

src/pawns.cpp

index 921e53b..c8c41f2 100644 (file)
@@ -129,7 +129,7 @@ namespace {
         // Score this pawn
         if (support | phalanx)
         {
-            int v = (phalanx ? 3 : 2) * Connected[r];
+            int v = (phalanx ? 3 : 2) * Connected[r] * (r == RANK_2 && pos.captures_to_hand() ? 3 : 1);
             if (r >= RANK_4 && pos.count<PAWN>(Us) > popcount(pos.board_bb()) / 4)
                 v = std::max(v, popcount(support | phalanx) * 100);
             v = 17 * popcount(support) + (v >> (opposed + 1));