X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=moves.c;h=463935d56e2e822dd145a66729443bd0cb1348ee;hb=f7e7dc832cce623d716a05b2be6c63c8cae541d7;hp=8380f1bd21b67a2337b187d7b5c9d3345892bf29;hpb=d78e0b2bc1c4390b7afe294d94146cb682e29fb2;p=xboard.git diff --git a/moves.c b/moves.c index 8380f1b..463935d 100644 --- a/moves.c +++ b/moves.c @@ -1229,6 +1229,7 @@ void DisambiguateCallback(board, flags, kind, rf, ff, rt, ft, closure) cl->rt = wildCard ? cl->rtIn : rt; cl->ft = wildCard ? cl->ftIn : ft; cl->kind = kind; + cl->captures += (board[cl->rt][cl->ft] != EmptySquare); // [HGM] oneclick: count captures } } @@ -1239,7 +1240,7 @@ void Disambiguate(board, flags, closure) { int illegal = 0; char c = closure->promoCharIn; - closure->count = 0; + closure->count = closure->captures = 0; closure->rf = closure->ff = closure->rt = closure->ft = 0; closure->kind = ImpossibleMove; if (appData.debugMode) {