xScal Scaleform API 0.4.34

Input: mouse

Mouse capture. While captured, raw-input mouse records are added to the totals Input.PollMouse returns and are not passed to Fallout 76.

Input.BeginMouseCapture

Start capturing mouse input

__SFCodeObj.call("Input.BeginMouseCapture"):Boolean

No arguments.

Returns Boolean

Resets the totals and starts capture. Returns false when the game window subclass could not be installed; capture stays on and the next call retries the install.

Input.PollMouse

Read and reset mouse totals

__SFCodeObj.call("Input.PollMouse"):String

No arguments.

Returns String (JSON)

FieldTypeDescription
dxintHorizontal motion in raw mouse units.
dyintVertical motion in raw mouse units.
wheelintWheel delta, 120 per notch.
leftBooleanLeft button physically held.
rightBooleanRight button physically held.
leftPressedBooleanLeft button went down since the previous poll.
rightPressedBooleanRight button went down since the previous poll.
capturingBoolean

Sample result

{"dx":12,"dy":-3,"wheel":120,"left":false,"right":false,"leftPressed":false,"rightPressed":false,"capturing":true}

Returns the motion and wheel totals since the previous poll and resets them. Relative motion only: records with absolute coordinates (tablets, remote desktop) add no motion. All values are zero and capturing is false while capture is off.

Input.EndMouseCapture

Stop capturing mouse input

__SFCodeObj.call("Input.EndMouseCapture"):Boolean

No arguments.

Returns Boolean

Always true.