Skip to the content

Jirai地雷

Deal seeded minefields, prove hints from visible clues and mount square, orthogonal, hexagonal or wraparound boards.

Jirai is the Japanese word 地雷 for a land mine. About the name

Contents

Reference

Four-neighbour rules

import { … } from "@johnmorrisdotca/jirai/orthogonal";

6.6 kB minified and gzipped, with everything it imports (measured with esbuild)

Exports

NameKindWhat it is
decodeOrthogonalGamefunctionRestores only version 2 orthogonal progress records.
encodeOrthogonalGamefunctionEncodes an orthogonal game with an explicit variant marker and version 2.
makeOrthogonalBoardfunctionDeals a board whose clues count only up, down, left and right.
newOrthogonalGamefunctionStarts a game under four-neighbour rules.
ORTHOGONAL_VARIANTconstantIdentifies the four-neighbour rules and progress-code format.
orthogonalHintfunctionGives a clue-only deduction; flags remain notes and cannot influence the result.
orthogonalNeighboursfunctionReturns the adjacent cells under the orthogonal rules.
OrthogonalSettingstypeSettings accepted by the four-neighbour-specific helpers.

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/jirai 0.5.0.