Skip to the content

Gunjin軍人

Play five hidden-rank games, keep setups private, share redacted views and replay, and pass one device between players.

Gunjin is the Japanese word 軍人 for a soldier. About the name

Contents

Reference · Hidden capture-flag rules

STRATEGO_LITE_RULESconstant

Original streamlined capture-flag rules using the published Original roster and combat table.

Import it

import { STRATEGO_LITE_RULES } from "@johnmorrisdotca/gunjin/stratego-lite";

Definition

const STRATEGO_LITE_RULES: ModeRules = {
    mode: "stratego-lite",
    defaultWidth: 10,
    defaultHeight: 10,
    acceptsSize: (width, height) => width === 10 && height === 10,
    roster: () => ROSTER,
    validateSetup,
    legalDestinations,
    resolveMove,
}

Members

NameTypeDescription
modeGameMode
defaultWidthnumber
defaultHeightnumber
acceptsSize(width: number, height: number) => boolean
roster(player: Player, width: number, height: number) => readonly string[]
validateSetup(player: Player, placements: readonly SetupPiece[]) => boolean
legalDestinations(match: AuthoritativeMatch, piece: Piece) => readonly Coordinate[]
resolveMove(match: AuthoritativeMatch, piece: Piece, destination: Coordinate) => MoveResolution

Examples

import { STRATEGO_LITE_RULES } from "@johnmorrisdotca/gunjin/stratego-lite";

console.log(STRATEGO_LITE_RULES.mode);
stratego-lite

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/gunjin 0.2.1.