import { randInt } from "@/utils/alea";
export class GrasshopperRules extends ChessRules {
+
static get HasEnpassant() {
return false;
}
return Object.assign(
{},
ChessRules.PawnSpecs,
- {
- twoSquares: false,
- promotions: ChessRules.PawnSpecs.promotions.concat([V.GRASSHOPPER])
- }
+ { promotions: ChessRules.PawnSpecs.promotions.concat([V.GRASSHOPPER]) }
);
}
return 2;
}
- static GenRandInitFen(randomness) {
- return ChessRules.GenRandInitFen(randomness)
+ static GenRandInitFen(options) {
+ return ChessRules.GenRandInitFen(options)
.slice(0, -2)
.replace(
"/pppppppp/8/8/8/8/PPPPPPPP/",
"/gggggggg/pppppppp/8/8/PPPPPPPP/GGGGGGGG/"
);
}
+
};