natiny.input.get_cursor

Lua
natiny.input.get_cursor() -> cursor

Returns the last cursor shape accepted by Natiny. The initial shape is natiny.input.CURSOR_ARROW.

Returns

Type Description
integer Current cursor setting; one of the constants listed by natiny.input.set_cursor

Example

Lua
local before = natiny.input.get_cursor()
natiny.input.set_cursor(natiny.input.CURSOR_FORBIDDEN)

-- Restore the previous cursor shape.
natiny.input.set_cursor(before)