diff --git a/app/src/main/cpp/skyline/input/npad_device.cpp b/app/src/main/cpp/skyline/input/npad_device.cpp index f506fae8..3d89599e 100644 --- a/app/src/main/cpp/skyline/input/npad_device.cpp +++ b/app/src/main/cpp/skyline/input/npad_device.cpp @@ -187,6 +187,7 @@ namespace skyline::input { info.header.timestamp = util::GetTimeTicks(); info.header.entryCount = std::min(static_cast(info.header.entryCount + 1), constant::HidEntryCount); + info.header.maxEntry = constant::HidEntryCount - 1; info.header.currentEntry = (info.header.currentEntry != constant::HidEntryCount - 1) ? info.header.currentEntry + 1 : 0; auto &entry{info.state.at(info.header.currentEntry)}; diff --git a/app/src/main/cpp/skyline/input/sections/common.h b/app/src/main/cpp/skyline/input/sections/common.h index 8aa3c25b..00d04214 100644 --- a/app/src/main/cpp/skyline/input/sections/common.h +++ b/app/src/main/cpp/skyline/input/sections/common.h @@ -21,7 +21,7 @@ namespace skyline { u64 timestamp; //!< The timestamp of the latest entry in ticks u64 entryCount; //!< The number of written entries u64 currentEntry; //!< The index of the latest entry - u64 maxEntry{constant::HidEntryCount - 1}; //!< The maximum entry index (16) + u64 maxEntry; //!< The maximum entry index }; static_assert(sizeof(CommonHeader) == 0x20); } diff --git a/app/src/main/cpp/skyline/input/touch.cpp b/app/src/main/cpp/skyline/input/touch.cpp index a9ed9d49..17222a20 100644 --- a/app/src/main/cpp/skyline/input/touch.cpp +++ b/app/src/main/cpp/skyline/input/touch.cpp @@ -37,6 +37,7 @@ namespace skyline::input { section.header.timestamp = util::GetTimeTicks(); section.header.entryCount = std::min(static_cast(section.header.entryCount + 1), constant::HidEntryCount); + section.header.maxEntry = constant::HidEntryCount - 1; section.header.currentEntry = entryIndex; } }