X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fnotation.cpp;h=9893569c742378cd62a1c4bbc9d63bf86c4ea005;hp=371b08a1a264b2b4d3e41953a73c2ca7b3d45d41;hb=a89b26bedd7e07f23c8292dcdccbd527c68d56f4;hpb=fcf2a34080404b90cac46184d76e8f2cdda16bd2 diff --git a/src/notation.cpp b/src/notation.cpp index 371b08a1..9893569c 100644 --- a/src/notation.cpp +++ b/src/notation.cpp @@ -43,7 +43,7 @@ string score_to_uci(Value v, Value alpha, Value beta) { stringstream ss; if (abs(v) < VALUE_MATE_IN_MAX_PLY) - ss << "cp " << v * 100 / int(PawnValueMg); + ss << "cp " << v * 100 / int(PawnValueEg); else ss << "mate " << (v > 0 ? VALUE_MATE - v + 1 : -VALUE_MATE - v) / 2; @@ -132,9 +132,9 @@ const string move_to_san(Position& pos, Move m) { while (b) { - Square sq = pop_lsb(&b); - if (!pos.legal(make_move(sq, to), pos.pinned_pieces(us))) - others ^= sq; + Square s = pop_lsb(&b); + if (!pos.legal(make_move(s, to), pos.pinned_pieces(us))) + others ^= s; } if (!others) @@ -207,7 +207,7 @@ static string format(Value v) { ss << "-#" << (VALUE_MATE + v) / 2; else - ss << setprecision(2) << fixed << showpos << double(v) / PawnValueMg; + ss << setprecision(2) << fixed << showpos << double(v) / PawnValueEg; return ss.str(); }