]> git.sesse.net Git - stockfish/blobdiff - src/movepick.h
Scale down stat bonus
[stockfish] / src / movepick.h
index 652ef16166d8295b8d2561e03b00e3a866ae6071..457defa525aacbf53b3333e7f707a7104bb7ae6b 100644 (file)
@@ -51,7 +51,7 @@ public:
     assert(abs(bonus) <= D); // Ensure range is [-D, D]
     static_assert(D <= std::numeric_limits<T>::max(), "D overflows T");
 
-    entry += bonus - entry * abs(bonus) / D;
+    entry += (bonus * D - entry * abs(bonus)) / (D * 5 / 4);
 
     assert(abs(entry) <= D);
   }