Fix key input function continuing on button releases

This commit is contained in:
Yuri Kunde Schlesner 2015-05-14 04:25:25 -03:00
parent 121c93ba11
commit 76997590c7

View File

@ -4,7 +4,8 @@ u32 InputWait() {
u32 pad_state_old = HID_STATE; u32 pad_state_old = HID_STATE;
while (true) { while (true) {
u32 pad_state = HID_STATE; u32 pad_state = HID_STATE;
if (pad_state ^ pad_state_old) if ((pad_state ^ pad_state_old) & pad_state)
return ~pad_state; return ~pad_state;
pad_state_old = pad_state;
} }
} }