Reference · Numbered puzzle levels
MeikyuuMazeLeveltype
A numbered flat-maze recipe, difficulty measures, cell count and place within its size.
Import it
import type { MeikyuuMazeLevel } from "@johnmorrisdotca/meikyuu/levels";
Definition
type MeikyuuMazeLevel = Base & {
readonly kind: "maze";
readonly recipe: MazeRecipe;
readonly cells: number;
readonly score: number;
readonly size: MeikyuuSize;
readonly inSize: number;
};
Members
| Name | Type | Description |
|---|---|---|
number | number | Its place in its own list, from 1. |
code | string | The recipe as one short word. |
effort | number | What it measures (see |
rating | number | The effort as a rating from 1 to 100 on the scale of the maze list. |
kind | "maze" | |
recipe | MazeRecipe | |
cells | number | |
score | number | How hard it is to play, from 0 to 100 (see |
size | "small" | "medium" | "large" | "huge" | The size it belongs to, as |
inSize | number | Its place among the levels of its size, from 1: the number a person playing that size meets it at. |
Examples
import type { MeikyuuMazeLevel } from "@johnmorrisdotca/meikyuu/levels";
import { levelOf } from "@johnmorrisdotca/meikyuu/levels";
const value: MeikyuuMazeLevel = levelOf("maze",1)!;
console.log(value);{
kind: 'maze',
number: 1,
code: 'square:3x5:prim:to-goal:1538214105',
effort: 22,
rating: 15,
score: 13,
cells: 15,
size: 'small',
inSize: 1,
recipe: {
shape: 'square',
w: 3,
h: 5,
algorithm: 'prim',
mode: 'to-goal',
seed: 1538214105
}
}What it prints (run when this page was built)