X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=board.c;fp=board.c;h=8df780b01c600489fc75fcc48536a87597fdce7a;hb=7be221b22bc0e10fa8c2b71b6506398d1f42cb0f;hp=48f075de4db5447a4d5d0697c9f38aefc18aae83;hpb=0db5357126541c6de9c1ebf57209b2ae1ba394d2;p=xboard.git diff --git a/board.c b/board.c index 48f075d..8df780b 100644 --- a/board.c +++ b/board.c @@ -599,7 +599,7 @@ void AnimateMove (Board board, int fromX, int fromY, int toX, int toY) { ChessSquare piece; - int hop; + int hop, x = toX, y = toY; Pnt start, finish, mid; Pnt frames[kFactor * 2 + 1]; int nFrames, startColor, endColor; @@ -616,6 +616,10 @@ AnimateMove (Board board, int fromX, int fromY, int toX, int toY) piece = board[fromY][fromX]; if (piece >= EmptySquare) return; + if(killX >= 0) toX = killX, toY = killY; // [HGM] lion: first to kill square + +again: + #if DONT_HOP hop = FALSE; #else @@ -653,6 +657,8 @@ AnimateMove (Board board, int fromX, int fromY, int toX, int toY) /* Be sure end square is redrawn */ damage[0][toY][toX] |= True; + + if(toX != x || toY != y) { fromX = toX; fromY = toY; toX = x; toY = y; goto again; } // second leg } void