-import { ChessRules, Move, PiPo } from "@/base_rules";
-import { SuicideRules } from "@/variants/Suicide";
-import { ArrayFun } from "@/utils/array";
-import { randInt } from "@/utils/alea";
+import ChessRules from "/base_rules";
+import GiveawayRules from "/variants/Giveaway";
+
+// TODO + display bonus messages
+// + animation + multi-moves for bananas/bombs/mushrooms
+
+
+
+import { ArrayFun } from "/utils/array";
+import { randInt } from "/utils/alea";
+import PiPo from "/utils/PiPo.js";
+import Move from "/utils/Move.js";
export class ChakartRules extends ChessRules {
static get PawnSpecs() {
return SuicideRules.PawnSpecs;
}
-
- static get HasCastle() {
+ get hasCastle() {
return false;
}
-
- static get HasEnpassant() {
+ get hasEnpassant() {
return false;
}
- static get CorrConfirm() {
- // Because of bonus effects
- return false;
- }
-
- static get CanAnalyze() {
- return false;
- }
-
- static get SomeHiddenMoves() {
- return true;
- }
-
static get IMMOBILIZE_CODE() {
return {
'p': 's',
return "*";
}
- static GenRandInitFen(options) {
+ genRandInitFen(seed) {
+ const gr = new GiveawayRules({}, true);
return (
- SuicideRules.GenRandInitFen(options).slice(0, -1) +
+ gr.genRandInitFen(seed).slice(0, -1) +
// Add Peach + Mario flags + capture counts
- "1111 000000000000"
+ '{"flags": "1111", "ccount": "000000000000"}'
);
}