Remove cap in kingDanger initialization
authorRocky640 <Rocky640@users.noreply.github.com>
Sat, 29 Apr 2017 03:36:24 +0000 (20:36 -0700)
committerJoona Kiiski <joona@zoox.com>
Sat, 29 Apr 2017 03:38:03 +0000 (20:38 -0700)
Passed STC
http://tests.stockfishchess.org/tests/view/58fd53be0ebc59035df33eb5
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 52048 W: 9397 L: 9329 D: 33322

Passed LTC
http://tests.stockfishchess.org/tests/view/58ff9e0a0ebc59035df33f5c
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 35382 W: 4650 L: 4549 D: 26183

Bench: 5872717

Closes #1087

src/evaluate.cpp

index 2f60edd..e381d6f 100644 (file)
@@ -424,7 +424,7 @@ namespace {
         // number and types of the enemy's attacking pieces, the number of
         // attacked and undefended squares around our king and the quality of
         // the pawn shelter (current 'score' value).
-        kingDanger =  std::min(820, ei.kingAttackersCount[Them] * ei.kingAttackersWeight[Them])
+        kingDanger =        ei.kingAttackersCount[Them] * ei.kingAttackersWeight[Them]
                     + 103 * ei.kingAdjacentZoneAttacksCount[Them]
                     + 190 * popcount(undefended)
                     + 142 * (popcount(b) + !!pos.pinned_pieces(Us))