X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fuci.cpp;h=718c78752502b61bd991b25191c94b2d30487e41;hp=a9ace955e81b342ab50df69f6a870d0ae9fbebe3;hb=258da28e79d99f75e0b626697bda2d459a37c0e6;hpb=d8e56cbe54378c91fbbd9e6f6cee8ef5a27b02e9 diff --git a/src/uci.cpp b/src/uci.cpp index a9ace955..718c7875 100644 --- a/src/uci.cpp +++ b/src/uci.cpp @@ -83,9 +83,6 @@ void uci_loop() { else if (token == "go") go(pos, is); - else if (token == "ucinewgame") - pos.from_fen(StartFEN, false); - else if (token == "isready") cout << "readyok" << endl; @@ -105,10 +102,7 @@ void uci_loop() { pos.flip_me(); else if (token == "eval") - { - EvalRootColor = pos.side_to_move(); - cout << trace_evaluate(pos) << endl; - } + cout << Eval::trace(pos) << endl; else if (token == "key") cout << "key: " << hex << pos.key() @@ -181,14 +175,10 @@ namespace { while (is >> token) value += string(" ", !value.empty()) + token; - if (!Options.count(name)) - cout << "No such option: " << name << endl; - - else if (value.empty()) // UCI buttons don't have a value - Options[name] = true; - - else + if (Options.count(name)) Options[name] = value; + else + cout << "No such option: " << name << endl; }