Skip to content

ZeroTrace HID

Mouse Commands

Move the cursor, click, drag, scroll, and run automated mouse patterns — the full relative mouse command set

Mouse commands move the cursor and click relative to its current position. They are sent over USB‑HID only.

How arguments work

Every argument is expanded first, so ${var}$ and operators like _$random(...) work anywhere. Argument counts are matched exactly — a command given the wrong number of arguments is silently skipped.

Relative movement only

Only relative positioning is available to scripts. Absolute‑positioning routines exist in the controller but are not wired to the scripting engine, so there is no way to move the cursor to a fixed screen coordinate from a payload.

Buttons

Every clicking command takes a button name. Supported buttons: left, right, middle, backward, forward. An unknown (or omitted) button falls back to left.

Moving the cursor

Moves the cursor by x/y relative to its current position, in one HID report. Values are 16‑bit (-3276732767).

mouseMove 50 -30

Clicking

Clicks a button. Add hold to press and keep it down, or release to let it up.

mouseClick left
mouseClick right hold
mouseClick right release

Scrolling

Scrolls the wheel by amount (8‑bit, -127127). Positive scrolls up, negative scrolls down.

mouseScroll 5
mouseScroll -3

Movement patterns and jitter

Random micro‑movements for durationMs, moving every posDelay ms, optionally clicking each step. All four arguments are required.

mouseJitter 5000 100 true left

Arguments: <durationMs> <posDelay> <click(true|false)> <button>.

Tricks
  • mouseMoveSoft always uses 10 internal steps — tune smoothness with delayMs, not step count. Use mouseMoveSmooth when you need to set the step count yourself.
  • mouseDragDrop offsets are 8‑bit; for a long drag use mouseDraw (16‑bit) instead.
  • mouseSpiral leaves the left button held until it finishes — don't interleave other clicks inside it.
  • A stray mouseMoveSmooth … 0 … (zero steps) does nothing at all; the command guards against divide‑by‑zero by no‑opping.

Command Palette

Search for a command to run...