X-Git-Url: https://git.auder.net/?a=blobdiff_plain;f=client%2Fsrc%2Fvariants%2FMadhouse.js;h=72c41cd889ae55248be6f258967865aa8122256f;hb=7c05a5f2297bea540c700ebceb0cc8b03a7f6775;hp=c157437d43c6ff6c45b0b3fe7034c6a57a5bddf6;hpb=a9e1202b681d9d2f814767180183a0b04c58f8ab;p=vchess.git diff --git a/client/src/variants/Madhouse.js b/client/src/variants/Madhouse.js index c157437d..72c41cd8 100644 --- a/client/src/variants/Madhouse.js +++ b/client/src/variants/Madhouse.js @@ -2,7 +2,8 @@ import { ChessRules, Move, PiPo } from "@/base_rules"; import { randInt } from "@/utils/alea"; export class MadhouseRules extends ChessRules { - hoverHighlight(x, y) { + + hoverHighlight([x, y]) { // Testing move validity results in an infinite update loop. // TODO: find a way to test validity anyway. return (this.subTurn == 2 && this.board[x][y] == V.EMPTY); @@ -254,4 +255,5 @@ export class MadhouseRules extends ChessRules { move.appear[0].p != V.PAWN ? move.appear[0].p.toUpperCase() : ""; return piece + "@" + V.CoordsToSquare(move.end); } + };