作る

LobbyState

Canonical representation of a multiplayer lobby.

LobbyState

Canonical representation of a multiplayer lobby.

Properties

lobbyId

lobbyId: string

Permanent id for the lobby used by the backend.

code

code: string

Short shareable code a friend can type to join.

hostId

hostId: string

Player id for the current host.

players

players: {    userId: string;    name: string;}[]

Current roster with ids + display names.

maxPlayers

maxPlayers: number

Max capacity configured at creation time.

status

status: "waiting" | "playing" | "finished"

Lifecycle stage for the lobby.