int x = (ponder[0] != 0); // during ponder stm is the opponent\r
int black = (stm == BLACK ^ x ^ sc == 's'); // set if our color is what the engine calls black\r
int nr = moveNr + x; // we ponder for one move ahead!\r
+ int t = (flob ? inc + myTime/40 : 1000*byo*(byo>0)); // byoyomi time \r
if(sc == 'x') black = 1; else drawOffer = 0;// in UCCI 'black' refers to us and 'white' to opponent\r
if(!x && drawOffer) ponder = " draw", drawOffer = 0; //pass draw offer only when not pondering\r
- fprintf(toE, "\ngo%s %stime %d %stime %d", ponder, bTime, black ? myTime : hisTime, wTime, !black ? myTime : hisTime);\r
- DPRINT( "\n# go%s %stime %d %stime %d", ponder, bTime, black ? myTime : hisTime, wTime, !black ? myTime : hisTime);\r
+ fprintf(toE, "\ngo%s %stime %d %stime %d", ponder, bTime, (black ? myTime : hisTime) - t, wTime, (!black ? myTime : hisTime) - t);\r
+ DPRINT( "\n# go%s %stime %d %stime %d", ponder, bTime, (black ? myTime : hisTime) - t, wTime, (!black ? myTime : hisTime) - t);\r
if(sTime > 0) { fprintf(toE, " movetime %d", sTime); DPRINT(" movetime %d", sTime); } else\r
if(mps) { fprintf(toE, " movestogo %d", mps*(nr/(2*mps)+1)-nr/2); DPRINT(" movestogo %d", mps*(nr/(2*mps)+1)-nr/2); }\r
- if(flob || byo >= 0) sprintf(suffix, " byoyomi %d", byo >=0 ? 1000*byo : inc + myTime/40); // for engines running purely on byoyomi\r
+ if(flob || byo >= 0) sprintf(suffix, " byoyomi %d", t); // for engines running purely on byoyomi\r
if(inc && !*suffix) { fprintf(toE, " %s %d %s %d", wInc, inc, bInc, inc); DPRINT(" %s %d %s %d", wInc, inc, bInc, inc); }\r
if(depth > 0) { fprintf(toE, " depth %d", depth); DPRINT(" depth %d", depth); }\r
if(*suffix) { fprintf(toE, suffix, inc); DPRINT(suffix, inc); }\r