mirror of
https://github.com/SunsetMkt/Akebi-GC.git
synced 2025-01-07 01:53:53 +08:00
Added debugging for animation changer
This commit is contained in:
parent
873b497051
commit
9c91ab3dfe
@ -350,6 +350,7 @@ DO_APP_FUNC(0x05BD9F90, void, Animator_Play, (Animator* __this, String* stateNam
|
||||
DO_APP_FUNC(0x05BDA110, void, Animator_Rebind, (Animator* __this, MethodInfo* method));
|
||||
DO_APP_FUNC(0x05BDA640, float, Animator_get_speed, (Animator* __this, MethodInfo* method));
|
||||
DO_APP_FUNC(0x05BDA770, void, Animator_set_speed, (Animator* __this, float value, MethodInfo* method));
|
||||
DO_APP_FUNC(0x04E510A0, String*, Extension_GetCurrentStateName, (Animator* animator, int32_t layer, AnimatorController* animCont, MethodInfo* method));
|
||||
|
||||
DO_APP_FUNC(0x05C5B3D0, bool, Behaviour_get_isActiveAndEnabled, (Behaviour* __this, MethodInfo* method));
|
||||
|
||||
|
@ -17,7 +17,8 @@ namespace cheat::feature
|
||||
NF(f_Animation, "Animation", "Visuals::AnimationChanger", "Attack01"),
|
||||
NF(f_ApplyKey, "Apply Animation", "Visuals::AnimationChanger", Hotkey('Y')),
|
||||
NF(f_ResetKey, "Reset Animation", "Visuals::AnimationChanger", Hotkey('R')),
|
||||
NF(f_Delay, "Repeat Delay", "Visuals::AnimationChanger", 400)
|
||||
NF(f_Delay, "Repeat Delay", "Visuals::AnimationChanger", 400),
|
||||
NF(f_Debug, "Debug Animations", "Visuals::AnimationChanger", false)
|
||||
{
|
||||
HookManager::install(app::MoleMole_PlayerModule_EntityAppear, MoleMole_PlayerModule_EntityAppear_Hook);
|
||||
events::GameUpdateEvent += MY_METHOD_HANDLER(AnimationChanger::OnGameUpdate);
|
||||
@ -53,6 +54,7 @@ namespace cheat::feature
|
||||
ConfigWidget("Apply Key", f_ApplyKey, true);
|
||||
ConfigWidget("Reset Key", f_ResetKey, true);
|
||||
ConfigWidget("Delay", f_Delay, 1, 1, 1000000000, "Delay to repeat animation");
|
||||
ConfigWidget(f_Debug, "Logs current active character's animation state.");
|
||||
}
|
||||
}
|
||||
ImGui::EndGroupPanel();
|
||||
@ -107,6 +109,9 @@ namespace cheat::feature
|
||||
|
||||
auto stateNamesArray = reinterpret_cast<app::AnimatorController*>(acComponent)->fields._stateNames;
|
||||
|
||||
if (f_Debug)
|
||||
LOG_DEBUG(il2cppi_to_string(app::Extension_GetCurrentStateName(avatar->animator(), 0, reinterpret_cast<app::AnimatorController*>(acComponent), nullptr)).c_str());
|
||||
|
||||
static bool isFull = false;
|
||||
for (int i = 0; i < stateNamesArray->max_length && !isFull; i++)
|
||||
{
|
||||
|
@ -13,6 +13,7 @@ namespace cheat::feature
|
||||
config::Field<Hotkey> f_ApplyKey;
|
||||
config::Field<Hotkey> f_ResetKey;
|
||||
config::Field<int> f_Delay;
|
||||
config::Field<bool> f_Debug;
|
||||
|
||||
const FeatureGUIInfo& GetGUIInfo() const override;
|
||||
void DrawMain() override;
|
||||
|
Loading…
x
Reference in New Issue
Block a user