diff --git a/UnleashedRecomp/api/SWA/System/InputState.h b/UnleashedRecomp/api/SWA/System/InputState.h index defe936e..7bb00ca9 100644 --- a/UnleashedRecomp/api/SWA/System/InputState.h +++ b/UnleashedRecomp/api/SWA/System/InputState.h @@ -11,10 +11,9 @@ namespace SWA // TODO: Hedgehog::Base::TSynchronizedPtr static CInputState* GetInstance(); - SPadState m_PadStates[40]; - SWA_INSERT_PADDING(0x50); + SWA_INSERT_PADDING(0x4); + SPadState m_PadStates[8]; be m_CurrentPadStateIndex; - SWA_INSERT_PADDING(0x04); const SPadState& GetPadState() const; }; diff --git a/UnleashedRecomp/api/SWA/System/InputState.inl b/UnleashedRecomp/api/SWA/System/InputState.inl index 5eba9408..7b961c4d 100644 --- a/UnleashedRecomp/api/SWA/System/InputState.inl +++ b/UnleashedRecomp/api/SWA/System/InputState.inl @@ -3,7 +3,7 @@ namespace SWA // TODO: Hedgehog::Base::TSynchronizedPtr inline CInputState* CInputState::GetInstance() { - return *(xpointer*)MmGetHostAddress(0x833671EC); + return *(xpointer*)MmGetHostAddress(0x83361F5C); } inline const SPadState& CInputState::GetPadState() const diff --git a/UnleashedRecomp/api/SWA/System/PadState.h b/UnleashedRecomp/api/SWA/System/PadState.h index 9b9a21d6..a27df47d 100644 --- a/UnleashedRecomp/api/SWA/System/PadState.h +++ b/UnleashedRecomp/api/SWA/System/PadState.h @@ -43,16 +43,11 @@ namespace SWA struct SPadState { - SWA_INSERT_PADDING(0x20); - be DownState; be UpState; be TappedState; be ReleasedState; - // TODO: This structure seems different than the Generations counterpart, - // these paddings might not be there. - be LeftStickHorizontal; be LeftStickVertical; @@ -66,7 +61,7 @@ namespace SWA be LeftTrigger; be RightTrigger; - SWA_INSERT_PADDING(0x24); + SWA_INSERT_PADDING(0x08); bool IsDown(const EKeyState in_Keys) const; bool IsUp(const EKeyState in_Keys) const;