|
Lua API
0.4.0
Game Engine
|
Functions | |
| isKeyPressed (key) | |
| Checks, if the given key is currently pressed. More... | |
| onKeyDown (key) | |
| Checks, if the given key got pressed in this frame. More... | |
| onKeyUp (key) | |
| Checks, if the given key got released in this frame. More... | |
| getAxis (axis) | |
| Retrieves the current axis value of a joystick or mouse. More... | |
| getProperty (name) | |
| getTouchPosition (touchId) | |
| Retrieves the current touch position on touch devices. More... | |
| getLastTouchPosition (touchId) | |
| getTouchPhase (touchId) | |
| getAxis | ( | axis | ) |
Retrieves the current axis value of a joystick or mouse.
The value is between 0.0 and 1.0
See also: http://www.neo-engine.de/wordpress/?wpwtds_article=key-and-axis-literals
| The | name of the key. |
| getLastTouchPosition | ( | touchId | ) |
| getProperty | ( | name | ) |
| getTouchPhase | ( | touchId | ) |
| getTouchPosition | ( | touchId | ) |
Retrieves the current touch position on touch devices.
Is the same as the mouse cursor position since SDL makes no difference between them.
| The | touch device ID |
| isKeyPressed | ( | key | ) |
Checks, if the given key is currently pressed.
See also: http://www.neo-engine.de/wordpress/?wpwtds_article=key-and-axis-literals
| The | name of the key. |
| onKeyDown | ( | key | ) |
Checks, if the given key got pressed in this frame.
See also: http://www.neo-engine.de/wordpress/?wpwtds_article=key-and-axis-literals
| The | name of the key. |
| onKeyUp | ( | key | ) |
Checks, if the given key got released in this frame.
See also: http://www.neo-engine.de/wordpress/?wpwtds_article=key-and-axis-literals
| The | name of the key. |