X-Git-Url: https://git.auder.net/?a=blobdiff_plain;f=client%2Fsrc%2Fvariants%2FChakart.js;h=5f20132ea48fe68294224e08c3349ecaa1ba3c8b;hb=b2e8c34e0158f512741d67b8a1c25425e0b8747e;hp=f170f707a18995dfdcda33697459b8c61560c284;hpb=7c05a5f2297bea540c700ebceb0cc8b03a7f6775;p=vchess.git diff --git a/client/src/variants/Chakart.js b/client/src/variants/Chakart.js index f170f707..5f20132e 100644 --- a/client/src/variants/Chakart.js +++ b/client/src/variants/Chakart.js @@ -1422,7 +1422,7 @@ export class ChakartRules extends ChessRules { let notation = undefined; if (piece == V.PAWN) { // Pawn move - if (move.vanish.length >= 2) { + if (this.board[move.end.x][move.end.y] != V.EMPTY) { // Capture const startColumn = V.CoordToColumn(move.start.y); notation = startColumn + "x" + finalSquare; @@ -1435,7 +1435,7 @@ export class ChakartRules extends ChessRules { else { notation = piece.toUpperCase() + - (move.vanish.length >= 2 ? "x" : "") + + (this.board[move.end.x][move.end.y] != V.EMPTY ? "x" : "") + finalSquare; } if (!!move.end.effect) {