Skip to the content

Meikyuu迷宮

Generate seeded mazes and arrow puzzles, follow numbered levels, and play on flat grids or three-dimensional surfaces.

Meikyuu is the Japanese word 迷宮 for labyrinth. About the name

Contents

Reference · Playable surface mazes

SolidEventDetailtype

What every event tells of the board.

Import it

import type { SolidEventDetail } from "@johnmorrisdotca/meikyuu/3d/play";

Definition

type SolidEventDetail = {
    kind: "solid";
    solid: SolidRecipe["kind"];
    moves: number;
    cells: number;
    solved: boolean;
    stones: number;
    stonesLeft: number | null;
};

Members

NameTypeDescription
kind"solid"
solidSolidKind
movesnumber
cellsnumber
solvedboolean
stonesnumber
stonesLeftnumber | null

Examples

import type { SolidRecipe } from "@johnmorrisdotca/meikyuu/3d";
import { buildSolidMaze } from "@johnmorrisdotca/meikyuu/3d";
import type { SolidEventDetail } from "@johnmorrisdotca/meikyuu/3d/play";
import { stonesLeft } from "@johnmorrisdotca/meikyuu";

const solidRecipe: SolidRecipe = {kind:"cube",n:2,algorithm:"backtracker",seed:42};
const solid = buildSolidMaze(solidRecipe);
const value: SolidEventDetail = {kind:"solid",solid:"cube",moves:0,cells:0,solved:false,stones:0,stonesLeft:null};
console.log(value);
{
  kind: 'solid',
  solid: 'cube',
  moves: 0,
  cells: 0,
  solved: false,
  stones: 0,
  stonesLeft: null
}

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/meikyuu 3.2.0.