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

holdInput

holdInput<Value>(headlessGame, handle, value): void

Holds handle at value in what every step from here reads, as a player holding a key does: a button held or let go, an axis, a vector or an angle at the step nearest the value. An edge button, such as characters.inputs.jump, is pressed once: the next step takes it. holdInput(game, characters.inputs.move, { x: 0, y: 1 }) walks her forward.

Type Parameter
Value extends InputValue
Parameter Type
headlessGame HeadlessGame
handle InputHandle<Value>
value Value

void