Skip to content

input_handler

Methods

is_key_pressed(key): bool

Type Name Description Default
number key Key to check none

Checks if key is pressed or not. Refer to MSDN for key codes

1
local mouse1_held = input_handler.is_key_pressed(1)

get_cursor_pos(): number, number

Returns cursor x and y

1
local mx, my = input_handler.get_cursor_pos()