mirror of
https://github.com/wiiu-env/PayloadLoaderInstaller.git
synced 2024-11-17 23:49:15 +01:00
20 lines
465 B
C
20 lines
465 B
C
|
#pragma once
|
||
|
|
||
|
class CombinedInput : public Input {
|
||
|
public:
|
||
|
void combine(const Input &b) {
|
||
|
data.buttons_h |= b.data.buttons_h;
|
||
|
}
|
||
|
|
||
|
void process() {
|
||
|
data.buttons_d |= (data.buttons_h & (~lastData.buttons_h));
|
||
|
data.buttons_r |= (lastData.buttons_h & (~data.buttons_h));
|
||
|
lastData.buttons_h = data.buttons_h;
|
||
|
}
|
||
|
|
||
|
void reset() {
|
||
|
data.buttons_h = 0;
|
||
|
data.buttons_d = 0;
|
||
|
data.buttons_r = 0;
|
||
|
}
|
||
|
};
|