ChaiLove API
0.28.0
|
Represents a physical joystick. More...
Public Member Functions | |
std::string | getName () |
Gets the name of the joystick. More... | |
bool | isDown (int button) |
Checks if a button on the Joystick is pressed. More... | |
bool | isDown (const std::string &button) |
Checks if a button on the Joystick is pressed. More... | |
bool | isConnected () |
Gets whether the Joystick is connected. More... | |
int | getID () |
Gets the joystick's unique identifier. More... | |
Represents a physical joystick.
int love::Types::Input::Joystick::getID | ( | ) |
Gets the joystick's unique identifier.
std::string love::Types::Input::Joystick::getName | ( | ) |
Gets the name of the joystick.
bool love::Types::Input::Joystick::isConnected | ( | ) |
Gets whether the Joystick is connected.
bool love::Types::Input::Joystick::isDown | ( | int | button | ) |
Checks if a button on the Joystick is pressed.
button | The index of the button to be checked |
bool love::Types::Input::Joystick::isDown | ( | const std::string & | button | ) |
Checks if a button on the Joystick is pressed.
button | The button to be checked |