X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fevaluate.cpp;h=35764b717207e38b3871f367d4edbe5c400f8fc6;hp=177d29345fa38613143630e7a01564f4ce58039b;hb=c5828c4eba9e4e3f448e8370f24804da719a5120;hpb=b4f6728e610848b202cee47af28fa3bb0a251e3c diff --git a/src/evaluate.cpp b/src/evaluate.cpp index 177d2934..35764b71 100644 --- a/src/evaluate.cpp +++ b/src/evaluate.cpp @@ -210,7 +210,7 @@ namespace { // in KingDanger[]. Various little "meta-bonuses" measuring the strength // of the enemy attack are added up into an integer, which is used as an // index to KingDanger[]. - Score KingDanger[512]; + Score KingDanger[400]; // KingAttackWeights[PieceType] contains king attack weights by piece type const int KingAttackWeights[PIECE_TYPE_NB] = { 0, 0, 7, 5, 4, 1 }; @@ -706,9 +706,9 @@ namespace { // ...count safe + (behind & safe) with a single popcount int bonus = popcount((Us == WHITE ? safe << 32 : safe >> 32) | (behind & safe)); bonus = std::min(16, bonus); - int weight = pos.count(Us); + int weight = pos.count(Us) - 2 * ei.pi->open_files(); - return make_score(bonus * weight * weight / 22, 0); + return make_score(bonus * weight * weight / 18, 0); }