本文へ移動

Hitotsu一つ

色か数字をそろえて出し、手札が1枚になったら声をかけます。クラシックやパーティーのルールで、コンピューターや共有のテーブルで遊べます。

「ヒトツ」は「一つ」。手札が1枚になったときに言う言葉です。 名前について(英語)

目次

リファレンス · ゲームとテーブル

startHitotsu関数

リファレンスの説明と例は英語です。見出しと目次は日本語です。

Deal a new seeded game for two to eight players at a supported match length; null for an unsupported length or player count.

インポート

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

定義

function startHitotsu(size: number, players: readonly string[], seed?: number, options?: HitotsuOptions, computers?: readonly boolean[]): HitotsuGame | null

引数

名前型説明
sizenumber

The match length: 1 for one hand, or 200 or 500 points.

playersreadonly string[]

The two to eight player names in seat order.

seed (省略可)number

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

options (省略可)HitotsuOptions

Native table, rules, sound or drawing settings; omitted fields retain their defaults.

computers (省略可)readonly boolean[] | undefined

Computer-controlled seats: flags for a game, seat indices for a shared table.

戻り値

HitotsuGame | null

Deal a new seeded game for two to eight players at a supported match length; null for an unsupported length or player count.

例

import { HITOTSU_CLASSIC, startHitotsu } from "@johnmorrisdotca/hitotsu";

console.log(startHitotsu(1, ["Aki", "Ben"], 42, HITOTSU_CLASSIC)?.hands.map((hand) => hand.length));
[ 7, 7 ]

出力(このページを作ったときに実行した結果)

ソースを見るGitHub で編集@johnmorrisdotca/hitotsu 1.4.0 のソースから作成しました。

この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。