int Threshold = 800;\r
int Score;\r
int makruk;\r
-int prom, pm;\r
+int prom, pm, gating;\r
char piecename[32], piecetype[32], blacktype[32];\r
char selectedFairy[80];\r
char *inifile = INI_FILE;\r
R -= 2*(-k/FAC);\r
UnderProm = -1; pl[WHITE] = pl[BLACK] = 2*BW; \r
pm = !pl[BLACK+7] && pl[BLACK+9] && pl[WHITE+7] ? 2 : 0; // Unlike white, black has no 'Q', so promote to 9, which he does have.\r
+ if(gating) pl[13] = pl[15] = pl[29] = pl[31] = 1, R += 2*(w[6]/FAC + w[8]/FAC);\r
}\r
\r
void CopyBoard(int s)\r
if(fscanf(f, "version 4.8(%c)", &c)!=1 || c != 'w')\r
{ printf("telluser incompatible fmax.ini file\n"); exit(0); }\r
\r
+ gating = 0;
if(name != NULL)\r
{ /* search for game name in definition file */\r
- if(!strcmp(name, "fairy")) name = selectedFairy;\r
+ if(!strcmp(name, "fairy")) name = selectedFairy;
+ gating = !strcmp(name, "seirawan");\r
while((ptc=fscanf(f, "Game: %s # %s", buf, pieceToChar))==0 || strcmp(name, buf) ) {\r
while((c = fgetc(f)) != EOF && c != '\n');\r
count++;\r
sscanf(line, "variant %s", command);\r
LoadGame(command);\r
InitGame(); Setup = 0;\r
- if(strstr(command,"seirawan")) pl[13] = pl[15] = pl[29] = pl[31] = 1, R += 2*(w[6]/FAC + w[8]/FAC);\r
continue;\r
}\r
if (!strcmp(command, "edit")) {\r