Skip to content
Work in progress. These docs describe Spawnite at launch, and some parts are still being built.

defineScenario

defineScenario(options): Scenario

Declares a scenario at module scope, under a game’s test/scenarios/: the scene, where the player’s character spawns, who plays and how the page draws, so spawnite scenario <name> runs it headless as a test and spawnite play profile --scenario <name> measures it. Its name is its export’s in kebab case, so export const groveWalk is grove-walk.

Parameter Type
options ScenarioOptions

Scenario