本文へ移動

Kumimoji組み文字

シードから配った英字やかなのタイルで、ひとりでも複数人の卓でも、単語を組み合わせて遊べます。

「組み文字」は文字を組み合わせることを表す言葉です。 名前について(英語)

目次

リファレンス · ルール・タイル・記録

leaveParty関数

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

A PLAYER LEAVES. Their tiles go back into the bag and the bag is shuffled — with the game's own seed and how far it has gone, so the same game left the same way deals the same tiles after a reload. A wild goes back blank.

The bag is kept as a line whose first taken tiles are the ones held, less what was traded back (holdsItsBag); after a leave it is written afresh as exactly that: the tiles everybody still holds, then the shuffled rest, with nothing traded back. Every seat after the leaver's moves up one, and the unnamed players keep the names they were shown ("Player 3" stays Player 3).

If it was their turn, the turn passes to the next still in, or in the last round to the next still to have their last turn; a last round with nobody left to play ends. With nobody still in — everybody left has resigned — the game ends tied between them.

インポート

import { leaveParty } from "@johnmorrisdotca/kumimoji";

定義

function leaveParty(game: PartyGame, at: number): PartyGame

引数

名前型説明
gamePartyGame

The current immutable shared-bag party game.

atnumber

The word offset, seat index or date specified by this signature.

戻り値

PartyGame

A PLAYER LEAVES. Their tiles go back into the bag and the bag is shuffled — with the game's own seed and how far it has gone, so the same game left the same way deals the same tiles after a reload. A wild goes back blank.

例

import { leaveParty, startParty } from "@johnmorrisdotca/kumimoji";

const settings = {size:3,level:"hard",seed:44,gameLength:"short",language:"english",doubleSet:false,diagonals:false,hints:false} as const;
const bag = "catdogsun";
const game = startParty(settings,bag,["Seat 1","Seat 2"]);
console.log(leaveParty(game,0).players.length);
1

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

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

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