hid: Filled in the Gc trigger fields.

This commit is contained in:
yellows8 2020-11-17 10:59:36 -05:00 committed by fincs
parent 5aaf6905dd
commit a924fac0ab
No known key found for this signature in database
GPG Key ID: 62C7609ADA219C60
2 changed files with 6 additions and 6 deletions

View File

@ -577,8 +577,8 @@ typedef struct HidNpadGcState {
u64 buttons;
JoystickPosition joysticks[JOYSTICK_NUM_STICKS];
u32 connectionState;
u32 unk0;
u32 unk1;
u32 l_trigger; ///< L analog trigger. Valid range: 0x0-0x7FFF.
u32 r_trigger; ///< R analog trigger. Valid range: 0x0-0x7FFF.
u32 pad;
} HidNpadGcState;
@ -631,8 +631,8 @@ typedef struct HidControllerLayout {
/// HidNpadGcTriggerState
typedef struct HidNpadGcTriggerState {
u64 timestamp;
u32 unk0;
u32 unk1;
u32 l_trigger;
u32 r_trigger;
} HidNpadGcTriggerState;
/// HidNpadGcTriggerStateEntry

View File

@ -610,8 +610,8 @@ void hidGetNpadStatesGc(u32 id, HidNpadGcState *states, size_t count, size_t *to
memcpy(states[i].joysticks, tmp_entries[i].joysticks, sizeof(tmp_entries[i].joysticks)); // sdknso uses index 0 for the src here.
states[i].connectionState = tmp_entries[i].connectionState;
states[i].unk0 = tmp_entries_trigger[i].unk0;
states[i].unk1 = tmp_entries_trigger[i].unk1;
states[i].l_trigger = tmp_entries_trigger[i].l_trigger;
states[i].r_trigger = tmp_entries_trigger[i].r_trigger;
}
}