Skip to the content

Hitotsu一つ

Match the colour or number, call with one card left, and play classic or party rules against computers or at a shared table.

Hitotsu is Japanese for one: the call with one card left. About the name

Contents

Reference · Game engine and table

shuffledHitotsufunction

The deck shuffled for one hand of one game: the same seed and hand always the same order.

Import it

import { shuffledHitotsu } from "@johnmorrisdotca/hitotsu";

Definition

function shuffledHitotsu(seed: number, hand: number): HitotsuCard[]

Parameters

NameTypeDescription
seednumber

The numeric seed that reproduces the same random sequence or deal.

handnumber

The hand number for deterministic shuffling, or the held cards where an array is accepted.

Returns

string[]

The deck shuffled for one hand of one game: the same seed and hand always the same order.

Examples

import { shuffledHitotsu } from "@johnmorrisdotca/hitotsu";

console.log(shuffledHitotsu(42, 0).slice(0, 7));
[
  'BD0', 'B80',
  'G61', 'R00',
  'WF2', 'B20',
  'G00'
]

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/hitotsu 1.4.0.