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

colourOffunction

A card's colour, or null for a wild.

Import it

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

Definition

function colourOf(card: HitotsuCard): HitotsuColour | null

Parameters

NameTypeDescription
cardstring

The physical card id; null draws the back where supported.

Returns

HitotsuColour | null

The card’s colour, or null for a wild card.

Examples

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

console.log(colourOf("WW0"));
null

What it prints (run when this page was built)

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