{ "opt", ArgSettingsFilename, (void *) NULL, FALSE, INVALID },
{ "loadPositionFile", ArgFilename, (void *) &appData.loadPositionFile, FALSE, INVALID },
{ "tourneyFile", ArgFilename, (void *) &appData.tourneyFile, FALSE, INVALID },
+ { "is", ArgString, (void *) &icsNick, FALSE, INVALID },
{ "loadGameFile", ArgFilename, (void *) &appData.loadGameFile, FALSE, INVALID },
{ "", ArgNone, NULL, FALSE, INVALID },
/* keyword arguments */
char *q;
int i, octval;
char ch;
- int posarg = 3; // default is game file
+ int posarg = 4; // default is game file
ch = get(cl);
for (;;) {
appData.viewer = TRUE;
} else if(!strcasecmp(argValue + len, ".ini") || !strcasecmp(argValue + len, ".xop")) {
ad = &argDescriptors[0]; // correct implied type to -opt
+ } else if(GetEngineLine(argValue, 11)) {
+ ad = &argDescriptors[3]; // correct implied type to -is
} else { // keep default -lgf, but let it imply viewer mode as well
appData.viewer = TRUE;
}
char buf[MSG_SIZ];
extern char *icsNames;
if(!s || !*s) return 0;
- NamesToList(n == 10 ? icsNames : firstChessProgramNames, command, mnemonic, "all");
+ NamesToList(n >= 10 ? icsNames : firstChessProgramNames, command, mnemonic, "all");
for(i=1; mnemonic[i]; i++) if(!strcmp(s, mnemonic[i])) break;
if(!mnemonic[i]) return 0;
+ if(n == 11) return 1; // just testing if there was a match
snprintf(buf, MSG_SIZ, "-%s %s", n == 10 ? "icshost" : "fcp", command[i]);
if(n == 1) SwapEngines(n);
ParseArgsFromString(buf);