Skip to the content

Tenka天下

Play seeded world conquest for two to six, with dice battles, cards, computer players and saved games.

Tenka means the world under heaven in Japanese. About the name

Contents

Reference · Rules, maps and records

startTenkafunction

A NEW GAME, all of it drawn from seed: who goes first; the territories shuffled and dealt round the table one at a time from that player, each with one army on it (at a table of two, dealt three ways, the neutral army taking every third); the cards shuffled; and each player's starting armies (TENKA_STARTING_ARMIES) less the ones already on their territories — scattered at random when placing is auto, or left to be placed by hand, one at a time round the table. The neutral army's are always scattered.

Null for a table the game is not offered for, or a seed that is not one.

Import it

import { startTenka } from "@johnmorrisdotca/tenka";

Definition

function startTenka(rounds: number, players: readonly string[], seed: number, placing?: TenkaPlacing, map?: TenkaMapKey): TenkaGame | null

Parameters

NameTypeDescription
roundsnumber

The supported round limit for the table.

playersreadonly string[]

The two to six local player names.

seednumber

The unsigned 32-bit starting seed.

placing (optional)TenkaPlacing

Automatic or manual initial reinforcement placement.

map (optional)TenkaMapKey

The native world or Europe map to use.

Returns

TenkaGame | null

The initial game, or null for an invalid round limit, player count, seed, placement or map.

Examples

import { startTenka } from "@johnmorrisdotca/tenka";

console.log(startTenka(10,["Seat 1","Seat 2"],42)?.phase);
reinforce

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/tenka 2.2.0.