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 · Mazes, arrows and mixed boards

ArrowRecipetype

Everything that makes an arrow puzzle.

Import it

import type { ArrowRecipe } from "@johnmorrisdotca/meikyuu";

Definition

type ArrowRecipe = {
    readonly shape: ArrowShape;
    readonly w: number;
    readonly h: number;
    readonly longest: number;
    readonly seed: number;
    readonly locks?: number;
};

Members

NameTypeDescription
shape"square" | "heart" | "leaf" | "star" | "ring" | "diamond" | "cross" | "moon"
wnumber

Columns and rows of the board: the same for every shape but square.

hnumber
longestnumber

The most cells an arrow may have.

seednumber
locks (optional)number | undefined

How many arrows are locked until they are unlocked (the mixed puzzles).

Examples

import type { ArrowRecipe } from "@johnmorrisdotca/meikyuu";

const arrowRecipe: ArrowRecipe = {shape:"square",w:5,h:5,longest:3,seed:42};
const value: ArrowRecipe = arrowRecipe;
console.log(value);
{ shape: 'square', w: 5, h: 5, longest: 3, seed: 42 }

What it prints (run when this page was built)

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