mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2025-06-13 06:57:58 -05:00
npad: Return NpadButton in GetAndResetPressState
We were previously truncating this to a u32 as there were no known buttons that used the full 64 bits of this type. Fix this now that we know they are used.
This commit is contained in:
@ -19,7 +19,6 @@
|
||||
namespace Core::Memory {
|
||||
namespace {
|
||||
constexpr auto CHEAT_ENGINE_NS = std::chrono::nanoseconds{1000000000 / 12};
|
||||
constexpr u32 KEYPAD_BITMASK = 0x3FFFFFF;
|
||||
|
||||
std::string_view ExtractName(std::string_view data, std::size_t start_index, char match) {
|
||||
auto end_index = start_index;
|
||||
@ -61,7 +60,7 @@ u64 StandardVmCallbacks::HidKeysDown() {
|
||||
applet_resource
|
||||
->GetController<Service::HID::Controller_NPad>(Service::HID::HidController::NPad)
|
||||
.GetAndResetPressState();
|
||||
return press_state & KEYPAD_BITMASK;
|
||||
return static_cast<u64>(press_state & HID::NpadButton::All);
|
||||
}
|
||||
|
||||
void StandardVmCallbacks::DebugLog(u8 id, u64 value) {
|
||||
|
Reference in New Issue
Block a user