mirror of
https://github.com/PrimeDecomp/prime.git
synced 2025-12-16 00:57:00 +00:00
Link DolphinIController.cpp, start matching CSmallAllocPool
Former-commit-id: 228319e2a5
This commit is contained in:
28
include/Kyoto/Input/CControllerGamepadData.hpp
Normal file
28
include/Kyoto/Input/CControllerGamepadData.hpp
Normal file
@@ -0,0 +1,28 @@
|
||||
#ifndef __CCONTROLLERGAMEPADDATA_HPP__
|
||||
#define __CCONTROLLERGAMEPADDATA_HPP__
|
||||
|
||||
#include "Kyoto/Input/CControllerAxis.hpp"
|
||||
#include "Kyoto/Input/CControllerButton.hpp"
|
||||
|
||||
class CControllerGamepadData {
|
||||
public:
|
||||
void SetDeviceIsPresent(bool present) { x0_present = present; }
|
||||
bool DeviceIsPresent() const { return x0_present; }
|
||||
|
||||
const CControllerAxis& GetAxis(EJoyAxis axis) const { return x4_axes[axis]; }
|
||||
CControllerAxis& GetAxis(EJoyAxis axis) { return x4_axes[axis]; }
|
||||
|
||||
const CControllerButton& GetButton(EButton button) const { return x34_buttons[button]; }
|
||||
CControllerButton& GetButton(EButton button) { return x34_buttons[button]; }
|
||||
|
||||
const CControllerAxis& GetAnalogButton(EAnalogButton button) const { return x24_triggers[button]; }
|
||||
CControllerAxis& GetAnalogButton(EAnalogButton button) { return x24_triggers[button]; }
|
||||
|
||||
private:
|
||||
bool x0_present;
|
||||
CControllerAxis x4_axes[4];
|
||||
CControllerAxis x24_triggers[2];
|
||||
CControllerButton x34_buttons[12];
|
||||
};
|
||||
|
||||
#endif // __CCONTROLLERGAMEPADDATA_HPP__
|
||||
Reference in New Issue
Block a user