X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=xboard2uci.cpp;h=72e81e45f3c96574b5938543d10d1c202f16fd30;hb=07265afaa167049a447b4c5f43e5ef90c7451a49;hp=1ffda48329f90e8d6f6583196b8440d96e3000ce;hpb=ad2265d4fc54fc9ba99fc606e6174df34bfb4a0f;p=polyglot.git diff --git a/xboard2uci.cpp b/xboard2uci.cpp index 1ffda48..72e81e4 100644 --- a/xboard2uci.cpp +++ b/xboard2uci.cpp @@ -112,9 +112,9 @@ static void learn (int result); // functions -// xboard_init() +// xboard2uci_init() -void xboard_init() { +void xboard2uci_init() { // init game_clear(Game); @@ -161,26 +161,14 @@ void xboard_init() { XB->opp_time = 300.0; } -void xboard_step(char string[]) { +// xboard2uci_gui_step() + +void xboard2uci_gui_step(char string[]) { int move; char move_string[256]; board_t board[1]; - static bool firsttime=true; - - if(firsttime){ - if((match(string,"uci"))){ - my_log("POLYGLOT *** Switching to UCI mode ***\n"); - send_uci_options(); - option_set("UCI","true"); - return; - }else{ - //uci_send_isready(Uci); // In UCI mode this done by the GUI - //Grrr...Toga can fixes the number of threads after "isready" - //So we delay "isready" - } - firsttime=false; - } + if (false) { } else if (match(string,"accepted *")) { @@ -661,9 +649,9 @@ void xboard_step(char string[]) { return; } -// engine_step() +// xboard2uci_engine_step() -void engine_step(char string[]) { +void xboard2uci_engine_step(char string[]) { int event; event = uci_parse(Uci,string); @@ -851,7 +839,7 @@ static void comp_move(int move) { ASSERT(State->state==THINK); ASSERT(!XB->analyse); - if(option_get_bool("RepeatPV")==true) + if(option_get_bool("RepeatPV")) send_pv(); // to update time and nodes // send the move