Skip to the content

Tobiishi飛び石

Jump pegs on nine native boards, generate seeded solvable challenges and build a peg-solitaire player for your page.

Tobiishi is the Japanese word 飛び石 for stepping stones. About the name

Contents

Reference · Boards, rules and challenges

generateTobiishiChallengefunction

Creates one fixed-goal puzzle with a complete, replayable legal answer.

Import it

import { generateTobiishiChallenge } from "@johnmorrisdotca/tobiishi";

Definition

function generateTobiishiChallenge(packKey: Shape, goalId: string, difficulty: ChallengeDifficulty): GoalChallenge

Parameters

NameTypeDescription
packKeyShape

A supported native board/pack key.

goalIdstring

One of this pack’s named goal identifiers.

difficultyChallengeDifficulty

The requested easy, medium or hard witness-length category.

Returns

GoalChallenge

Creates one fixed-goal puzzle with a complete, replayable legal answer.

Examples

import { generateTobiishiChallenge } from "@johnmorrisdotca/tobiishi";

console.log(generateTobiishiChallenge("english","centre","easy").answer.length);
3

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/tobiishi 0.3.1.