int Threshold = 800;\r
int Score;\r
int makruk;\r
+int prom;\r
char piecename[32], piecetype[32], blacktype[32];\r
char *inifile = INI_FILE;\r
\r
}\r
if(z&S&&K-I) /* move pending: check legal*/\r
{if(v+I&&x==K&y==L) /* if move found */\r
- {Q=-e-i;O=F;LL=L;\r
- if(b[y]-u&15)b[y]-=PromPiece, /* under-promotion, correct */\r
+ {Q=-e-i;O=F;LL=L;prom=0;\r
+ if(b[y]-u&15)prom=b[y]-=PromPiece, /* under-promotion, correct */\r
J+=PromPiece; /* piece & invalidate hash */\r
a->D=99;a->V=0; /* lock game in hash as draw*/\r
R-=i/FAC; /*** total captd material ***/\r
printf("1-0 {Bare King}\n");\r
return 5;\r
}\r
- if(cnt>-I+1 && K==0 && L==0) {\r
- if (s == WHITE)\r
- printf("0-1 {Stalemate}\n");\r
- else\r
- printf("1-0 {Stalemate}\n");\r
- return 2;\r
- }\r
#else\r
if(cnt>-I+1 && K==0 && L==0) {\r
printf("1/2-1/2 {Stalemate}\n");\r
printf("move ");\r
printf("%c%c%c%c",'a'+(K&15),'0'+BH-(K>>4),\r
'a'+(L&15),'0'+BH-(L>>4));\r
+ if(prom)printf("%c",piecename[prom&15]+'a'-1);\r
printf("\n");\r
m = GetTickCount() - Ticks;\r
\r