Keyboard Input
SourcesInteractive keyboard source. Click the block to arm it, then steer with the
arrow keys or WASD — also while the simulation runs. Placing a KeyboardInput (or any
interactive input block) automatically switches the simulation to real-time pacing.
Inputs & Outputs
| Direction | ID | Label | Type | Status |
|---|---|---|---|---|
| ← Out | x |
X | number | Output |
| ← Out | y |
Y | number | Output |
Parameters
| Parameters | Label | Type | Default | Description |
|---|---|---|---|---|
keyX |
X State | number | 0 |
-1 (left/A), 0, or 1 (right/D) — written by the keyboard listener |
keyY |
Y State | number | 0 |
-1 (down/S), 0, or 1 (up/W) — written by the keyboard listener |
gain |
Gain | number | 1 |
Output scale: out = key state × gain |
Usage Examples
- Zie de ingebouwde voorbeelden in de handleiding voor een demonstratie van dit blok.
Remarks & Best Practices
- Configuratie: Configureer dit blok via de parameters in het paneel.
Related Components
- Constant: Eenvoudige signaalbron