Skip to the content

Houseki宝石

Run five native gem and stone engines, play measured challenges and lessons, and save deterministic games.

Houseki (宝石) is Japanese for a gem or precious stone. About the name

Contents

Reference · Tsumiki

createChallengefunction

Makes an authored game from its seed, goal and stones.

Import it

import { createChallenge } from "@johnmorrisdotca/houseki/tsumiki";

Definition

function createChallenge(options: ChallengeOptions): GameState

Parameters

NameTypeDescription
optionsChallengeOptions

The game's identity, seed, goal and stones.

Returns

GameState

A new game of that challenge.

Examples

import { createChallenge } from "@johnmorrisdotca/houseki/tsumiki";
console.log(createChallenge({ id: "one", seed: "s", goal: { kind: "lines", target: 1 } }).settings.mode);
challenge

What it prints (run when this page was built)

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