X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fevaluate.cpp;h=0249ee3b2a35c24071feb935069ed2e106926e59;hp=73ffcfb053057a6a203674dff264702940f55110;hb=1322ab97c737fe761bd6ae8786f852851b8f019f;hpb=a98dee783582c84ca2647ca28daad0c9a13d1d35 diff --git a/src/evaluate.cpp b/src/evaluate.cpp index 73ffcfb0..0249ee3b 100644 --- a/src/evaluate.cpp +++ b/src/evaluate.cpp @@ -1064,9 +1064,8 @@ namespace { } - // scale_by_game_phase() interpolates between a middle game and an endgame - // score, based on game phase. It also scales the return value by a - // ScaleFactor array. + // scale_by_game_phase() interpolates between a middle game and an endgame score, + // based on game phase. It also scales the return value by a ScaleFactor array. Value scale_by_game_phase(const Score& v, Phase ph, const ScaleFactor sf[]) { @@ -1076,7 +1075,7 @@ namespace { Value eg = eg_value(v); ScaleFactor f = sf[eg > Value(0) ? WHITE : BLACK]; - Value ev = Value((eg * f) / int(SCALE_FACTOR_NORMAL)); + Value ev = Value((eg * f) / SCALE_FACTOR_NORMAL); int result = (mg_value(v) * ph + ev * (128 - ph)) / 128; return Value(result & ~(GrainSize - 1));