printf("\n");\r
fflush(stdout);\r
}\r
- if(GetTickCount() - startTime > tlim1) break; // do not start iteration we can (most likely) not finish\r
+ if(!(abortFlag & 1) && GetTickCount() - startTime > tlim1) break; // do not start iteration we can (most likely) not finish\r
}\r
replyDep = iterDep;\r
#ifdef HASH\r
void\r
PonderUntilInput (int stm)\r
{\r
+MapFromScratch(attacks);\r
+ repCnt = 0; abortFlag = -1;\r
+ Search(-INF-1, INF+1, rootEval, maxDepth, sup1, sup2);\r
}\r
\r
int TakeBack(int n)\r
if(!strcmp(command, "put")) { ReadSquare(inBuf+4, &lastPut); continue; } // ditto\r
if(!strcmp(command, ".")) { inBuf[0] = 0; return; } // ignore for now\r
if(!strcmp(command, "lift")) { inBuf[0] = 0; Highlight(inBuf+5); return; } // treat here\r
+ abortFlag = 1;\r
return;\r
}\r
}\r
void\r
TerminationCheck()\r
{\r
+ if(abortFlag < 0) { // check for input\r
+ if(InputWaiting()) GetLine(0); // read & examine input command\r
+ } else { // check for time\r
if(GetTickCount() - startTime > tlim3) abortFlag = 2;\r
+ }\r
}\r
\r
main()\r