1 import ChessRules
from "/base_rules.js";
3 export default class CapablancaRules
extends ChessRules
{
6 return ['q', 'e', 's', 'r', 'n', 'b'];
16 [1, 0], [-1, 0], [0, 1], [0, -1]
21 [1, 2], [1, -2], [-1, 2], [-1, -2],
22 [2, 1], [-2, 1], [2, -1], [-2, -1]
33 [1, 1], [1, -1], [-1, 1], [-1, -1]
38 [1, 2], [1, -2], [-1, 2], [-1, -2],
39 [2, 1], [-2, 1], [2, -1], [-2, -1]
46 return Object
.assign(newPieces
, super.pieces(color
, x
, y
));
53 genRandInitBaseFen() {
54 const s
= FenUtil
.setupPieces(
55 ['r', 'n', 's', 'b', 'q', 'k', 'b', 'e', 'n', 'r'],
57 randomness: this.options
["randomness"],
58 between: {p1: 'k', p2: 'r'},
64 fen: s
.b
.join("") + "/pppppppppp/91/91/91/91/PPPPPPPPPP/" +
65 s
.w
.join("").toUpperCase(),