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/%7B%7B%20asset%28%27mixstore/css/static/current/%24%7BgetWhatsApp%28link%29%7D?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" );