19 #ifndef HEADER_GAMEPAD_DEVICE_HPP
20 #define HEADER_GAMEPAD_DEVICE_HPP
22 #include "input/input_device.hpp"
23 #include "utils/cpp2011.hpp"
34 void resetAxisDirection(
const int axis, Input::AxisDirection direction);
35 std::vector<bool> m_button_pressed;
37 std::vector<Input::AxisDirection> m_prev_axis_directions;
44 const int axis_number,
45 const int button_count,
48 bool isButtonPressed(
const int i);
49 void setButtonPressed(
const int i,
bool isButtonPressed);
52 InputManager::InputDriverMode mode,
56 bool moved(
int value)
const;
64 bool useForceFeedback()
const;
65 int getAutoCenterStrength()
const;
specialisation of Inputdevice for gamepad type devices
Definition: gamepad_device.hpp:33
bool moved(int value) const
Returns if the specified value is larger than the deadzone.
Definition: gamepad_device.cpp:64
virtual bool processAndMapInput(Input::InputType type, const int id, InputManager::InputDriverMode mode, PlayerAction *action, int *value=NULL) OVERRIDE
Invoked when this device it used.
Definition: gamepad_device.cpp:142
int getNumberOfButtons() const
Returns the number of buttons of this gamepad.
Definition: gamepad_device.cpp:72
int m_irr_index
Irrlicht index of this gamepad.
Definition: gamepad_device.hpp:40
int getIrrIndex() const
Returns the irrlicht index of this gamepad.
Definition: gamepad_device.hpp:60
virtual ~GamePadDevice()
Destructor for GamePadDevice.
Definition: gamepad_device.cpp:58
GamePadDevice(const int irrIndex, const std::string &name, const int axis_number, const int button_count, GamepadConfig *configuration)
Constructor for GamePadDevice from a connected gamepad for which no configuration existed (defaults w...
Definition: gamepad_device.cpp:31
specialisation of DeviceConfig for gamepad type devices
Definition: gamepad_config.hpp:43