What it does
input.getKey reads Key on an input object. It takes "w".
The API says: held
Signature
input.getKey("w")Arguments
"w"
Example · generated
function update(dt) { const key = input.getKey('w');}input.getKey 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.