send_event
Injects mouse, keyboard, text, and wheel input events into a running hx-multianim game for automated UI testing and control.
Instructions
Inject an input event into the running application. Event types:
click: mouse click (push + release) at x,y with button (0=left, 1=middle, 2=right)
mouse_down / mouse_up: separate push/release at x,y
move: mouse move to x,y
key_down / key_up: keyboard key press/release with keyCode (hxd.Key constants)
key_press: key_down + key_up combined
text: text input with charCode
wheel: mouse wheel with delta at x,y
Common key codes: SPACE=32, ENTER=13, ESCAPE=27, TAB=9, A=65, 0=48, UP=38, DOWN=40, LEFT=37, RIGHT=39, F1=112
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | No | Mouse X position (scene coordinates) | |
| y | No | Mouse Y position (scene coordinates) | |
| type | Yes | Event type | |
| delta | No | Mouse wheel delta (positive=scroll down) | |
| button | No | Mouse button: 0=left, 1=middle, 2=right | |
| keyCode | No | Keyboard key code (hxd.Key constants) | |
| charCode | No | Character code for text input |