X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=board.c;h=67e19cabec7b57b5c01f537f82a1bf6edbe11a03;hb=refs%2Fheads%2Fv4.9.x;hp=30cea29d4d2352ae944e241b3b3b8161fceba2a4;hpb=5fc6127768aaf96f59be69359e229dacbd2f44f7;p=xboard.git diff --git a/board.c b/board.c index 30cea29..2c1f7bb 100644 --- a/board.c +++ b/board.c @@ -194,7 +194,7 @@ SetPremoveHighlights (int fromX, int fromY, int toX, int toY) } if (pm2X != toX || pm2Y != toY) { if (pm2X >= 0 && pm2Y >= 0) { - damage[0][pm1Y][pm1X] |= 2; + damage[0][pm2Y][pm2X] |= 2; } } pm1X = fromX; @@ -235,7 +235,7 @@ SquareColor (int row, int column) { int square_color; - if (gameInfo.variant == VariantXiangqi) { + if (gameInfo.variant == VariantXiangqi || gameInfo.variant == VariantJanggi) { if (column >= 3 && column <= 5 && row >= 0 && row <= 2) { square_color = 1; } else if (column >= 3 && column <= 5 && row >= 7 && row <= 9) { @@ -605,7 +605,7 @@ AnimateMove (Board board, int fromX, int fromY, int toX, int toY) if (piece >= EmptySquare) return; if(x2 >= 0) toX = kill2X, toY = kill2Y; else - if(killX >= 0) toX = killX, toY = killY; // [HGM] lion: first to kill square + if(killX >= 0 && gameInfo.variant != VariantDuck) toX = killX, toY = killY; // [HGM] lion: first to kill square again: @@ -641,7 +641,7 @@ again: if(Explode(board, fromX, fromY, toX, toY)) { // mark as damaged int i,j; for(i=0; i 0) { @@ -914,7 +914,7 @@ SquareExpose(int i, int j, int d) } void -DrawPosition (int repaint, Board board) +DrawPositionX (int repaint, Board board) { int i, j, do_flash, exposeAll = False; static int lastFlipView = 0; @@ -1059,7 +1059,7 @@ DrawPosition (int repaint, Board board) q = strchr(p, '\n'); if(q) *q = NULLCHAR; if(!strstr(appData.suppress, p)) { - if(i == 0) DrawSeekBackground(2*squareSize, 3*squareSize, 6*squareSize, 5*squareSize); + if(i == 0) DrawSeekBackground(2*squareSize, 3*squareSize, 6.5*squareSize, 5*squareSize); DrawText(p, 2*squareSize + 5, (int) ((3 + 0.3*i++)*squareSize) + 5, 2); } if(q) *q++ = '\n'; else q = "";