Input
Route keyboard and mouse events while the game is active.
Input events
| Field | Type | Description |
|---|---|---|
| Type | string | KeyDown, KeyUp, Text, Paste, MouseDown, MouseUp, MouseMove or Wheel. |
| Code | number | Windows virtual-key code or mouse button number. |
| Text | string | UTF-8 text for Text or Paste. |
| Repeat | boolean | Whether a key-down event is an OS repeat. |
| Delta | number | Wheel movement in notches. |
Available functions
Context:destroyDestroys an input context.Context:geteventsDrains the input event queue.Context:getpasteReads text from a macOS paste event.Context:getpointerReads the pointer position in the game client.Context:setcaptureControls keyboard and mouse capture.Context:setregionSets the mouse capture region.input.createcontextCreates a script input context.input.isinterfaceactiveChecks whether native UI has suspended script input capture.iswindowactiveChecks whether a Vortex window is available for input.keyclickPresses and releases a key.keypressPresses a key.keyreleaseReleases a key.mouse1clickSends a left mouse click.mouse1pressPresses the left mouse button.mouse1releaseReleases the left mouse button.mouse2clickSends a right mouse click.mouse2pressPresses the right mouse button.mouse2releaseReleases the right mouse button.mousemoveabsMoves the pointer to a client position.mousemoverelMoves the pointer by a relative offset.mousescrollSends vertical scroll input.