MEIKYUU_MODES定数
リファレンスの説明と例は英語です。見出しと目次は日本語です。
A MAZE: a grid, the passages carved through it (always a spanning tree, so exactly one way between any two cells), and how it is played. The way to play is a declared field of the level, never inferred from the shape:
enter-leave: in at one door in the outer wall, out at another.to-goal: from a cell inside to a dot hidden deep in the maze.centre-out: from the middle of the shape to a door in the outer wall.keys: from a cell inside, collecting every key, to a door in the outer wall. A key is picked up by passing over it, and stays picked up if the line is drawn back.
A maze is a recipe (MazeRecipe) and nothing else: the same recipe makes the same maze in every
browser and every Node, because everything that decides it is integer arithmetic on a seeded stream.
インポート
import { MEIKYUU_MODES } from "@johnmorrisdotca/meikyuu";
定義
const MEIKYUU_MODES: readonly ["enter-leave", "to-goal", "centre-out", "keys"] = ["enter-leave", "to-goal", "centre-out", "keys"] as const
例
import { MEIKYUU_MODES } from "@johnmorrisdotca/meikyuu";
console.log(MEIKYUU_MODES);[ 'enter-leave', 'to-goal', 'centre-out', 'keys' ]出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。