![]() |
Contains information about a joystick number, an axis and its threshold. More...
Public Member Functions | |
JoystickAxis (unsigned int joystickId, sf::Joystick::Axis axis, float threshold, bool above) | |
Constructor. | |
Public Attributes | |
unsigned int | joystickId |
The joystick number. | |
sf::Joystick::Axis | axis |
The joystick axis. | |
float | threshold |
Position threshold above/below which an action is triggered. | |
bool | above |
True if position must be above threshold, false if below. |
Contains information about a joystick number, an axis and its threshold.
thor::JoystickAxis::JoystickAxis | ( | unsigned int | joystickId, |
sf::Joystick::Axis | axis, | ||
float | threshold, | ||
bool | above | ||
) |
Constructor.
Note that you can also construct a joystick id and axis property with the following more expressive syntax:
thor::JoystickAxis j1 = thor::joystick(id).axis(a).above(pos); thor::JoystickAxis j2 = thor::joystick(id).axis(a).below(pos);