MapWorldOptions beta
Interface of @v12-engine/engine
export interface MapWorldOptions extends WorldChecksWhat a world made from a map is made from: the map, the rules, and what the lobby chose for the players
Members
colors
colors?: Readonly<Record<PlayerId, [number, number, number]>>;The colour of each player, by player, over the map's (MapPlayer.color): chosen in a lobby
components
components?: readonly Component<unknown, unknown>[];Components the app keeps in the world beside the game's own, as CreateWorldOptions.components
creeps
creeps?: boolean;Whether the world has the creeps player. When the map has something for it when left out: a camp, or something placed for the creeps. A world without camps that had one anyway would never be won: a team would always be left
log
log?: Logger;The logger the world's own is made under, as CreateWorldOptions.log
map
map: GameMap;The map the world is made from: its terrain, players and what it places
navigation
navigation?: GameNavigationOptions;Options for how the world's units find their way, over the game's (Rules.navigation)
onError
onError?: ErrorPolicy;What becomes of a part of the game that throws, as CreateWorldOptions.onError
races
races?: Readonly<Record<PlayerId, string>>;The race each player plays, by player (Rules.races): one of the game's, or random. Chosen in a lobby, a page's own menu. Those left out play what the map fixes for them (MapPlayer.race), or the game's first
rules
rules: Rules;The game's rules the world runs
seed
seed?: number;Seed of the world's random numbers: the same seed gives the same game
teams
teams?: Readonly<Record<PlayerId, number>>;The team each player plays for, by player, over the map's (MapPlayer.team): chosen in a lobby