Skip to content

Type Alias: Preset ​

ts
type Preset = object;

Defined in: src/games/presets.ts:15

The dice for a game, and how the game reads them. A preset is data: a line here, not code. Korokoro rolls and reads the dice; it does not run the game (whose turn it is, a score sheet across rounds).

Properties ​

id ​

ts
id: string;

Defined in: src/games/presets.ts:17

A short name for code, links and the command line: "yahtzee", "cho-han".


name ​

ts
name: string;

Defined in: src/games/presets.ts:19

What people call the game.


nameJa ​

ts
nameJa: string;

Defined in: src/games/presets.ts:21

The same in Japanese, for the tray.


aliases ​

ts
aliases: string[];

Defined in: src/games/presets.ts:23

Other names it is found by: an older or public-domain name, a name in another language.


family ​

ts
family: GameFamily;

Defined in: src/games/presets.ts:24


notation ​

ts
notation: string;

Defined in: src/games/presets.ts:26

The dice, as notation.


reading ​

ts
reading: ReadingId;

Defined in: src/games/presets.ts:28

How a roll is read: one of the named readings.


options? ​

ts
optional options?: Record<string, number>;

Defined in: src/games/presets.ts:30

Figures a reading needs: a pool's target number, a game's main.


total ​

ts
total: boolean;

Defined in: src/games/presets.ts:32

Whether the total is what matters. False where the reading is the result, as in Yahtzee or chō-han.


rolls? ​

ts
optional rolls?: number;

Defined in: src/games/presets.ts:34

How many rolls a turn has when dice are held between them: 3 for Yahtzee. Left out when a turn is one roll.


hold? ​

ts
optional hold?: false;

Defined in: src/games/presets.ts:36

False where holding a die and rolling the rest is no part of the game, as in craps or Monopoly: the tray then holds nothing. Left out where dice are held between rolls (Yahtzee, Farkle).


runs? ​

ts
optional runs?: true;

Defined in: src/games/presets.ts:38

True where a roll is read in the light of the rolls before it: the point in craps, a turn's total in Pig.


says ​

ts
says: string;

Defined in: src/games/presets.ts:40

What it is, in a line.


saysJa ​

ts
saysJa: string;

Defined in: src/games/presets.ts:42

The same in Japanese.


how ​

ts
how: string;

Defined in: src/games/presets.ts:44

How the dice are used in the game, in a few sentences of our own.


source? ​

ts
optional source?: string;

Defined in: src/games/presets.ts:46

Where the rule can be read. Left out of a preset that has no rule to cite, such as a coin.

MIT © John Morris