love.keyreleased
Callback function triggered when a keyboard key is released.
Contents
Function
Available since LÖVE 0.10.0 |
This variant is not supported in earlier versions. |
Synopsis
love.keyreleased( key, scancode )
Arguments
KeyConstant key
- Character of the released key.
Scancode scancode
- The scancode representing the released key.
Returns
Nothing.
Notes
Scancodes are keyboard layout-independent, so the scancode "w" will be used if the key in the same place as the "w" key on an American keyboard is pressed, no matter what the key is labelled or what the user's operating system settings are.
Function
Synopsis
love.keyreleased( key )
Arguments
KeyConstant key
- Character of the released key.
Returns
Nothing.
Examples
Exit the game when the player releases the Escape key, using love.event.quit.
function love.keyreleased(key)
if key == "escape" then
love.event.quit()
end
end
See Also
Other Languages
Dansk –
Deutsch –
English –
Español –
Français –
Indonesia –
Italiano –
Lietuviškai –
Magyar –
Nederlands –
Polski –
Português –
Română –
Slovenský –
Suomi –
Svenska –
Türkçe –
Česky –
Ελληνικά –
Български –
Русский –
Српски –
Українська –
עברית –
ไทย –
日本語 –
正體中文 –
简体中文 –
Tiếng Việt –
한국어
More info