X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=backend.c;h=8b6d3c5843e0491ab2448b95d0753ca1dcc7e2da;hb=18ccb0da4151e649009780bd4db7ecbdea7a93c8;hp=0a7df4742b4596afdf4788562e7710e7feb8a351;hpb=61fffd7a94001160b3c4d35f84848971cb32c01d;p=xboard.git diff --git a/backend.c b/backend.c index 0a7df47..8b6d3c5 100644 --- a/backend.c +++ b/backend.c @@ -167,6 +167,7 @@ int FinishMove P((ChessMove moveType, int fromX, int fromY, int toX, int toY, /*char*/int promoChar)); void BackwardInner P((int target)); void ForwardInner P((int target)); +int Adjudicate P((ChessProgramState *cps)); void GameEnds P((ChessMove result, char *resultDetails, int whosays)); void EditPositionDone P((Boolean fakeRights)); void PrintOpponents P((FILE *fp)); @@ -5577,6 +5578,8 @@ FinishMove(moveType, fromX, fromY, toX, toY, promoChar) MakeMove(fromX, fromY, toX, toY, promoChar); /*updates forwardMostMove*/ + if(Adjudicate(NULL)) return 1; // [HGM] adjudicate: take care of automtic game end + if (gameMode == BeginningOfGame) { if (appData.noChessProgram) { gameMode = EditGame;