Skip to the content

Sugoroku双六

Play backgammon and its relatives with native rules, cube and match scoring, seeded dice and replayable records.

Sugoroku is the Japanese name 双六 for games of tables. About the name

Contents

Reference · Playable board

SugorokuLooktype

How the board looks, apart from the game.

Import it

import type { SugorokuLook } from "@johnmorrisdotca/sugoroku/play";

Definition

type SugorokuLook = {
    board?: SugorokuBoardName;
    checkers?: SugorokuCheckerSetName;
    colours?: Partial<SugorokuColours>;
    theme?: "auto" | "light" | "dark";
    home?: "left" | "right";
    view?: Side | "auto";
    numbers?: boolean;
    orientation?: Orientation | "auto";
};

Members

NameTypeDescription
board (optional)SugorokuBoardName | undefined
checkers (optional)SugorokuCheckerSetName | undefined
colours (optional)Partial<SugorokuColours> | undefined
theme (optional)"auto" | "light" | "dark" | undefined
home (optional)"left" | "right" | undefined

Which end of the board the trays are at.

view (optional)Side | "auto" | undefined

Whose home board is at the bottom: auto (the default) is the side a person plays when the computer plays the other, otherwise white.

numbers (optional)boolean | undefined

Numbers on the points.

orientation (optional)Orientation | "auto" | undefined

auto (the default) stands the board up in a narrow page, such as a phone's.

Examples

import type { SugorokuLook } from "@johnmorrisdotca/sugoroku/play";

const value: SugorokuLook = {board:"green",checkers:"contrast",numbers:true};
console.log(value);
{ board: 'green', checkers: 'contrast', numbers: true }

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/sugoroku 1.1.1.