lovr.keypressed

Edit

This callback is called when a key is pressed.

function lovr.keypressed(key, scancode, repeat)
  -- your code here
end

Arguments

NameTypeDescription
keyKeyCode The key that was pressed.
scancodenumber The id of the key (ignores keyboard layout, may vary between keyboards).
repeatboolean Whether the event is the result of a key repeat instead of an actual press.

Returns

Nothing

See also