VINDICTA
Input · Function
Bunni.fun
ChocoSploit
Cryptic
Potassium
Seliware
SirHurt
Solara
Velocity
Volcano
Volt
Wave
Xeno

mousemoveabs

Moves the mouse cursor to an absolute screen position.

function mousemoveabs(x: number, y: number): ()

Synopsis

How it works

Moves the mouse cursor to an absolute screen position. Uses SendInput with absolute coordinate mode:
INPUT input = {};
input.type = INPUT_MOUSE;
input.mi.dwFlags = MOUSEEVENTF_MOVE | MOUSEEVENTF_ABSOLUTE;
// Absolute coords use 0-65535 normalized range
input.mi.dx = (x * 65535) / screenWidth;
input.mi.dy = (y * 65535) / screenHeight;
SendInput(1, &input, sizeof(INPUT));
The MOUSEEVENTF_ABSOLUTE flag requires coordinates in a 0–65535 normalized range (not raw pixels). The executor handles the conversion internally. Coordinates are in screen space (primary monitor top-left = 0,0), not Roblox viewport space — factor in window position and title bar offset.

Usage

Move to screen centre
local vp = workspace.CurrentCamera.ViewportSize
mousemoveabs(vp.X / 2, vp.Y / 2)

Parameters

x number
Absolute X coordinate in screen pixels.
y number
Absolute Y coordinate in screen pixels.