Yuari
Documentation

getmousepos

Cursor position in client space.

Syntax

getmousepos() -> number

Parameters

This function takes no parameters.

Returns

TypeDescription
numberX, y

Description

getmousepos is part of the Input & clipboard library. Input helpers read or synthesize OS input and only report state while the game window is focused.

The call is read-only: it resolves the current value when invoked and does not change the underlying state.

Example

local x, y = getmousepos()
print(x, y)

Notes

  • Input status is focus-gated and only reports while the game is active.