What it does
input.getKeyDown reads KeyDown on an input object. It takes "space".
The API says: edge: just pressed
Signature
input.getKeyDown("space")Arguments
"space"
Example · generated
function update(dt) { const keyDown = input.getKeyDown('space');}input.getKeyDown is called with values of the shape its signature asks for. The code sits in update(dt), which the engine calls every frame: dt is the time since the last one, in seconds.