X-Git-Url: https://git.auder.net/?p=vchess.git;a=blobdiff_plain;f=client%2Fsrc%2Fvariants%2FColorbound.js;h=90e54dc4325aca770965116ed11ad2e5a4510854;hp=85f81ef3765979d26832a2d7bb72ce19e8ae1f97;hb=b90120e062404b8c656d4f38e66727df8a7e1c5a;hpb=459edd581fa23f511e224f07554944bbe53a2d70 diff --git a/client/src/variants/Colorbound.js b/client/src/variants/Colorbound.js index 85f81ef3..90e54dc4 100644 --- a/client/src/variants/Colorbound.js +++ b/client/src/variants/Colorbound.js @@ -63,16 +63,11 @@ export class ColorboundRules extends ChessRules { getPotentialMovesFrom([x, y]) { switch (this.getPiece(x, y)) { - case V.C_ROOK: - return this.getPotentialC_rookMoves([x, y]); - case V.C_KNIGHT: - return this.getPotentialC_knightMoves([x, y]); - case V.C_BISHOP: - return this.getPotentialC_bishopMoves([x, y]); - case V.C_QUEEN: - return this.getPotentialC_queenMoves([x, y]); - default: - return super.getPotentialMovesFrom([x, y]); + case V.C_ROOK: return this.getPotentialC_rookMoves([x, y]); + case V.C_KNIGHT: return this.getPotentialC_knightMoves([x, y]); + case V.C_BISHOP: return this.getPotentialC_bishopMoves([x, y]); + case V.C_QUEEN: return this.getPotentialC_queenMoves([x, y]); + default: return super.getPotentialMovesFrom([x, y]); } return []; }