From: Benjamin Auder Date: Sat, 25 Jul 2020 09:41:58 +0000 (+0200) Subject: Fix bug in Allmate2 X-Git-Url: https://git.auder.net/%3C?a=commitdiff_plain;h=6f10b38369cc92057a25cc0150727aeeeaa6f1d1;p=vchess.git Fix bug in Allmate2 --- diff --git a/client/src/variants/Allmate2.js b/client/src/variants/Allmate2.js index 9b60a5f6..259faa74 100644 --- a/client/src/variants/Allmate2.js +++ b/client/src/variants/Allmate2.js @@ -63,7 +63,7 @@ export class Allmate2Rules extends ChessRules { case V.KING: // Do not allow castling to escape from check oppMoves = super.getSlideNJumpMoves( - [x, y], + [i, j], V.steps[V.ROOK].concat(V.steps[V.BISHOP]), "oneStep" );