String *prms, Cardinal *nprms));
void TwoMachinesProc P((Widget w, XEvent *event, String *prms,
Cardinal *nprms));
+void MatchProc P((Widget w, XEvent *event, String *prms, Cardinal *nprms));
+void MatchOptionsProc P((Widget w, XEvent *event, String *prms, Cardinal *nprms));
void IcsClientProc P((Widget w, XEvent *event, String *prms,
Cardinal *nprms));
void EditGameProc P((Widget w, XEvent *event, String *prms, Cardinal *nprms));
{N_("Training"), "Training", TrainingProc},
{N_("ICS Client"), "ICS Client", IcsClientProc},
{"----", NULL, NothingProc},
+ {N_("Machine Match"), "Machine Match", MatchProc},
{N_("Pause Pause"), "Pause", PauseProc},
{NULL, NULL, NULL}
};
{N_("Common Engine ... Alt+Shift+U"), "Common Engine", UciMenuProc},
{N_("Adjudications ... Alt+Shift+J"), "Adjudications", EngineMenuProc},
{N_("ICS ..."), "ICS", IcsOptionsProc},
+ {N_("Match ..."), "Match", MatchOptionsProc},
{N_("Load Game ..."), "Load Game", LoadOptionsProc},
{N_("Save Game ..."), "Save Game", SaveOptionsProc},
// {N_(" ..."), "", OptionsProc},
{ "menuMode.Analysis Mode", False },
{ "menuMode.Analyze File", False },
{ "menuMode.Two Machines", False },
+ { "menuMode.Machine Match", False },
#ifndef ZIPPY
{ "menuEngine.Hint", False },
{ "menuEngine.Book", False },
{ "menuMode.Analysis Mode", False },
{ "menuMode.Analyze File", False },
{ "menuMode.Two Machines", False },
+ { "menuMode.Machine Match", False },
{ "menuMode.ICS Client", False },
{ "menuView.ICS Input Box", False },
{ "Action", False },
{ "menuMode.Machine White", False },
{ "menuMode.Machine Black", False },
{ "menuMode.Two Machines", False },
+ { "menuMode.Machine Match", False },
{ "menuEngine.Retract Move", False },
{ NULL, False }
};
{ "menuMode.Machine White", True },
{ "menuMode.Machine Black", True },
{ "menuMode.Two Machines", True },
+ { "menuMode.Machine Match", True },
{ "menuEngine.Retract Move", True },
{ NULL, False }
};
TwoMachinesEvent();
}
+void MatchProc(w, event, prms, nprms)
+ Widget w;
+ XEvent *event;
+ String *prms;
+ Cardinal *nprms;
+{
+ if(gameMode != BeginningOfGame) { DisplayError(_("You can only start a match from the initial position."), 0); return; }
+ matchMode = 2; // This is back-end, really\r
+ appData.matchGames = appData.defaultMatchGames;\r
+ matchGame = 1;\r
+ first.matchWins = second.matchWins = 0;\r
+ TwoMachinesEvent();
+}
+
void IcsClientProc(w, event, prms, nprms)
Widget w;
XEvent *event;
// cloned from Engine Settings dialog
-#define CURR -2000000000 /* indicates control should start at actual value of target */
-
typedef void ButtonCallback(int n);
char *trialSound;
void CreateXPMPieces P((void));
void GenericReadout();
+Option matchOptions[] = {
+{ 0, 2, 1000000000, NULL, (void*) &appData.defaultMatchGames, "", NULL, Spin, _("Default Number of Games in Match:") },
+{ 0, 0, 1000000000, NULL, (void*) &appData.matchPause, "", NULL, Spin, _("Pause between Match Games (msec):") },
+{ 0, 0, 0, NULL, (void*) &appData.loadGameFile, "", NULL, FileName, _("Game File with Opening Lines:") },
+{ 0, -2, 1000000000, NULL, (void*) &appData.loadGameIndex, "", NULL, Spin, _("Game Number (-1 or -2 = Auto-Increment):") },
+{ 0, 0, 0, NULL, (void*) &appData.loadPositionFile, "", NULL, FileName, _("File with Start Positions:") },
+{ 0, -2, 1000000000, NULL, (void*) &appData.loadPositionIndex, "", NULL, Spin, _("Position Number (-1 or -2 = Auto-Increment):") },
+{ 0, 0, 1000000000, NULL, (void*) &appData.rewindIndex, "", NULL, Spin, _("Rewind Index after this many Games (0 = never):") },
+{ 0, 0, 0, NULL, NULL, "", NULL, EndMark , "" }
+};
+
void GeneralOptionsOK(int n)
{
int newPonder = appData.ponderNextMove;
GenericPopUp(generalOptions, _("General Options"));
}
+void MatchOptionsProc(w, event, prms, nprms)
+ Widget w;
+ XEvent *event;
+ String *prms;
+ Cardinal *nprms;
+{
+ GenericPopUp(matchOptions, _("Match Options"));
+}
+
//---------------------------- Chat Windows ----------------------------------------------
void OutputChatMessage(int partner, char *mess)