Consider pieces in hand in king danger
authorianfab <ianfab@users.noreply.github.com>
Sat, 25 Aug 2018 17:27:42 +0000 (19:27 +0200)
committerFabian Fichter <ianfab@users.noreply.github.com>
Tue, 28 Aug 2018 17:35:58 +0000 (19:35 +0200)
STC crazyhouse
LLR: 2.96 (-2.94,2.94) [0.00,10.00]
Total: 583 W: 340 L: 231 D: 12
http://35.161.250.236:6543/tests/view/5b8191f06e23db0fbab0dcd6

src/evaluate.cpp

index 37106a3..2ce7aec 100644 (file)
@@ -490,6 +490,7 @@ namespace {
                      + 143 * popcount(pos.blockers_for_king(Us) | unsafeChecks)
                      - 848 * !pos.count<QUEEN>(Them)
                      -   9 * mg_value(score) / 8
+                     + 100 * (pos.piece_drops() ? pos.count_in_hand(Them, ALL_PIECES) : 0)
                      +  40;
 
         // Transform the kingDanger units into a Score, and subtract it from the evaluation