handSizeFor関数
リファレンスの説明と例は英語です。見出しと目次は日本語です。
HOW MANY TILES EACH PLAYER IS DEALT, by the set and the number at the table. Double-twelve's are the figures most published rules give (fifteen each for two to four, twelve for five or six, ten for seven or eight); the other sets are scaled so that at every table some tiles are left to draw.
インポート
import { handSizeFor } from "@johnmorrisdotca/domino";
定義
function handSizeFor(set: number, players: number): number
引数
| 名前 | 型 | 説明 |
|---|---|---|
set | number | The highest double of the supported set: 9, 12 or 15. |
players | number | Player count, or names in seat order, as specified by this signature. |
戻り値
number
HOW MANY TILES EACH PLAYER IS DEALT, by the set and the number at the table. Double-twelve's are the figures most published rules give (fifteen each for two to four, twelve for five or six, ten for seven or eight); the other sets are scaled so that at every table some tiles are left to draw.
例
import { handSizeFor } from "@johnmorrisdotca/domino";
console.log(handSizeFor(9,2));10出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。