From 0e1d14a8cc1c0a35d6b559c86f8296a2de9b79ee Mon Sep 17 00:00:00 2001 From: H.G.Muller Date: Thu, 6 Mar 2014 13:42:38 +0100 Subject: [PATCH] Use feature usermove=1 in XBoard mode By forcing the GUI to prefix the move with "usermove ", it will be easier to recognize whether a command is a move (e.g. for determining ponder hits in future ponder implementations). Moves are still recognized without such prefix as well, for the benefit of other modes. --- gnushogi/commondsp.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/gnushogi/commondsp.c b/gnushogi/commondsp.c index 4823f5f..56fe08b 100644 --- a/gnushogi/commondsp.c +++ b/gnushogi/commondsp.c @@ -1798,7 +1798,7 @@ InputCommand(char *command, int root) "shogi" #endif ); - printf("debug=1 setboard=1 sigint=0 memory=1 done=1\n"); + printf("debug=1 setboard=1 sigint=0 memory=1 usermove=1 done=1\n"); } else if (strcmp(s, ".") == 0) { // periodic update request of analysis info: send stat01 info @@ -2148,6 +2148,9 @@ InputCommand(char *command, int root) } else { + if (strcmp(s, "usermove") == 0) + sscanf(sx + 9, "%s", s); + if (flag.mate) { ok = true; -- 1.7.0.4