Talos docs

JoinScreenOptions

Since 0.7

The join screen's settings: the join-screen behavior's props.

Plain text

Every one is optional.

Signature

export interface JoinScreenOptions {
  /** Slots shown; default `ctx.players.max`, never above 4. */
  max?: number
  /** Seated players needed before a start; default 1. */
  minPlayers?: number
  /** Event raised once when everyone seated is ready; default `join-start`. */
  startEvent?: string
  /** Seconds between "all ready" and the start; any change in between cancels it. Default 0: start at once. */
  startDelay?: number
  /** The screen's name; default `join-screen`. */
  screen?: string
  /** The input context the screen asks for while it is up. */
  inputContext?: string
  /** Close `ctx.players` to new joiners when the start fires; default true. */
  closeJoining?: boolean
  /** Pop the screen when the start fires; default true. */
  popOnStart?: boolean
  /** Per-player choices (colour ids, character ids) a seated player cycles through before readying. */
  choices?: string[]
  /** With `choices`, no two players may hold the same one; default true. */
  uniqueChoices?: boolean
  /** Text overrides by `join.*` key. */
  strings?: Record<string, string>
}

Import: import type { JoinScreenOptions } from "@argus/gameplay"

Members

MemberSignatureDescription
maxmax?: numberSlots shown; default ctx.players.max, never above 4.
minPlayersminPlayers?: numberSeated players needed before a start; default 1.
startEventstartEvent?: stringEvent raised once when everyone seated is ready; default join-start.
startDelaystartDelay?: numberSeconds between "all ready" and the start; any change in between cancels it. Default 0: start at once.
screenscreen?: stringThe screen's name; default join-screen.
inputContextinputContext?: stringThe input context the screen asks for while it is up.
closeJoiningcloseJoining?: booleanClose ctx.players to new joiners when the start fires; default true.
popOnStartpopOnStart?: booleanPop the screen when the start fires; default true.
choiceschoices?: string[]Per-player choices (colour ids, character ids) a seated player cycles through before readying.
uniqueChoicesuniqueChoices?: booleanWith choices, no two players may hold the same one; default true.
stringsstrings?: Record<string, string>Text overrides by join.* key.