From: Benjamin Auder Date: Mon, 20 Jul 2020 09:50:48 +0000 (+0200) Subject: Add first draft of 'Victor Chess' X-Git-Url: https://git.auder.net/js/css/%7B%7B%20asset%28%27mixstore/images/current/gitweb.css?a=commitdiff_plain;h=c01212801607b7f6336d6378ad64872a19bb4f15;p=vchess.git Add first draft of 'Victor Chess' --- diff --git a/client/src/variants/Vchess.js b/client/src/variants/Vchess.js new file mode 100644 index 00000000..4e84eb0e --- /dev/null +++ b/client/src/variants/Vchess.js @@ -0,0 +1,17 @@ +import { ChessRules } from "@/base_rules"; + +export class VchessRules extends ChessRules { + static get PawnSpecs() { + return Object.assign( + {}, + ChessRules.PawnSpecs, + { captureBackward: true } + ); + } + + getNotation(move) { + let notation = super.getNotation(move); + // TODO: if capture backwards, add an indication 'b' + return notation; + } +};