[WIP] Animation Changer
This commit is contained in:
parent
30fec1e193
commit
2f433fd4e9
@ -21,6 +21,7 @@
|
|||||||
<ClInclude Include="src\user\cheat\misc\sniffer\pipe\PipeClient.h" />
|
<ClInclude Include="src\user\cheat\misc\sniffer\pipe\PipeClient.h" />
|
||||||
<ClInclude Include="src\user\cheat\misc\sniffer\pipe\PipeIO.h" />
|
<ClInclude Include="src\user\cheat\misc\sniffer\pipe\PipeIO.h" />
|
||||||
<ClInclude Include="src\user\cheat\player\AutoRun.h" />
|
<ClInclude Include="src\user\cheat\player\AutoRun.h" />
|
||||||
|
<ClInclude Include="src\user\cheat\visuals\AnimationChanger.h" />
|
||||||
<ClInclude Include="src\user\cheat\visuals\TextureChanger.h" />
|
<ClInclude Include="src\user\cheat\visuals\TextureChanger.h" />
|
||||||
<ClInclude Include="src\user\cheat\visuals\FreeCamera.h" />
|
<ClInclude Include="src\user\cheat\visuals\FreeCamera.h" />
|
||||||
<ClInclude Include="src\user\cheat\world\AutoSeelie.h" />
|
<ClInclude Include="src\user\cheat\world\AutoSeelie.h" />
|
||||||
@ -113,6 +114,7 @@
|
|||||||
<ClCompile Include="src\user\cheat\misc\sniffer\pipe\PipeClient.cpp" />
|
<ClCompile Include="src\user\cheat\misc\sniffer\pipe\PipeClient.cpp" />
|
||||||
<ClCompile Include="src\user\cheat\misc\sniffer\pipe\PipeIO.cpp" />
|
<ClCompile Include="src\user\cheat\misc\sniffer\pipe\PipeIO.cpp" />
|
||||||
<ClCompile Include="src\user\cheat\player\AutoRun.cpp" />
|
<ClCompile Include="src\user\cheat\player\AutoRun.cpp" />
|
||||||
|
<ClCompile Include="src\user\cheat\visuals\AnimationChanger.cpp" />
|
||||||
<ClCompile Include="src\user\cheat\visuals\TextureChanger.cpp" />
|
<ClCompile Include="src\user\cheat\visuals\TextureChanger.cpp" />
|
||||||
<ClCompile Include="src\user\cheat\visuals\FreeCamera.cpp" />
|
<ClCompile Include="src\user\cheat\visuals\FreeCamera.cpp" />
|
||||||
<ClCompile Include="src\user\cheat\world\AutoSeelie.cpp" />
|
<ClCompile Include="src\user\cheat\world\AutoSeelie.cpp" />
|
||||||
@ -219,6 +221,7 @@
|
|||||||
<Image Include="res\iconsHD\Andrius.png" />
|
<Image Include="res\iconsHD\Andrius.png" />
|
||||||
<Image Include="res\iconsHD\Azhdaha.png" />
|
<Image Include="res\iconsHD\Azhdaha.png" />
|
||||||
<Image Include="res\iconsHD\Boar.png" />
|
<Image Include="res\iconsHD\Boar.png" />
|
||||||
|
<Image Include="res\iconsHD\BookPage.png" />
|
||||||
<Image Include="res\iconsHD\Cat.png" />
|
<Image Include="res\iconsHD\Cat.png" />
|
||||||
<Image Include="res\iconsHD\Cicin.png" />
|
<Image Include="res\iconsHD\Cicin.png" />
|
||||||
<Image Include="res\iconsHD\Crane.png" />
|
<Image Include="res\iconsHD\Crane.png" />
|
||||||
@ -557,6 +560,7 @@
|
|||||||
<Image Include="res\icons\Andrius.png" />
|
<Image Include="res\icons\Andrius.png" />
|
||||||
<Image Include="res\icons\Azhdaha.png" />
|
<Image Include="res\icons\Azhdaha.png" />
|
||||||
<Image Include="res\icons\Boar.png" />
|
<Image Include="res\icons\Boar.png" />
|
||||||
|
<Image Include="res\icons\BookPage.png" />
|
||||||
<Image Include="res\icons\Cat.png" />
|
<Image Include="res\icons\Cat.png" />
|
||||||
<Image Include="res\icons\Cicin.png" />
|
<Image Include="res\icons\Cicin.png" />
|
||||||
<Image Include="res\icons\Crane.png" />
|
<Image Include="res\icons\Crane.png" />
|
||||||
|
@ -252,6 +252,9 @@
|
|||||||
<ClInclude Include="src\user\cheat\world\CustomWeather.h">
|
<ClInclude Include="src\user\cheat\world\CustomWeather.h">
|
||||||
<Filter>Header Files</Filter>
|
<Filter>Header Files</Filter>
|
||||||
</ClInclude>
|
</ClInclude>
|
||||||
|
<ClInclude Include="src\user\cheat\visuals\AnimationChanger.h">
|
||||||
|
<Filter>Header Files</Filter>
|
||||||
|
</ClInclude>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Font Include="res\Ruda-Bold.ttf" />
|
<Font Include="res\Ruda-Bold.ttf" />
|
||||||
@ -462,6 +465,9 @@
|
|||||||
<ClCompile Include="src\user\cheat\world\CustomWeather.cpp">
|
<ClCompile Include="src\user\cheat\world\CustomWeather.cpp">
|
||||||
<Filter>Source Files</Filter>
|
<Filter>Source Files</Filter>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
|
<ClCompile Include="src\user\cheat\visuals\AnimationChanger.cpp">
|
||||||
|
<Filter>Source Files</Filter>
|
||||||
|
</ClCompile>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ResourceCompile Include="res\res.rc">
|
<ResourceCompile Include="res\res.rc">
|
||||||
@ -2508,5 +2514,11 @@
|
|||||||
<Image Include="res\icons\Spincrocodile.png">
|
<Image Include="res\icons\Spincrocodile.png">
|
||||||
<Filter>Resource Files</Filter>
|
<Filter>Resource Files</Filter>
|
||||||
</Image>
|
</Image>
|
||||||
|
<Image Include="res\iconsHD\BookPage.png">
|
||||||
|
<Filter>Resource Files</Filter>
|
||||||
|
</Image>
|
||||||
|
<Image Include="res\icons\BookPage.png">
|
||||||
|
<Filter>Resource Files</Filter>
|
||||||
|
</Image>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
@ -344,6 +344,8 @@ DO_APP_FUNC(0x057E9D10, int32_t, Camera_get_pixelHeight, (Camera* __this, Method
|
|||||||
DO_APP_FUNC(0x0579EB70, int32_t, Screen_get_width, (MethodInfo* method));
|
DO_APP_FUNC(0x0579EB70, int32_t, Screen_get_width, (MethodInfo* method));
|
||||||
DO_APP_FUNC(0x0579EB00, int32_t, Screen_get_height, (MethodInfo* method));
|
DO_APP_FUNC(0x0579EB00, int32_t, Screen_get_height, (MethodInfo* method));
|
||||||
|
|
||||||
|
DO_APP_FUNC(0x05822EE0, void, Animator_Play, (Animator* __this, String* stateName, int32_t layer, float normalizedTime, MethodInfo* method));
|
||||||
|
DO_APP_FUNC(0x05823060, void, Animator_Rebind, (Animator* __this, MethodInfo* method));
|
||||||
DO_APP_FUNC(0x058236F0, void, Animator_set_speed, (Animator* __this, float value, MethodInfo* method));
|
DO_APP_FUNC(0x058236F0, void, Animator_set_speed, (Animator* __this, float value, MethodInfo* method));
|
||||||
|
|
||||||
DO_APP_FUNC(0x058AE2D0, bool, Behaviour_get_isActiveAndEnabled, (Behaviour* __this, MethodInfo* method));
|
DO_APP_FUNC(0x058AE2D0, bool, Behaviour_get_isActiveAndEnabled, (Behaviour* __this, MethodInfo* method));
|
||||||
|
@ -55,6 +55,7 @@
|
|||||||
#include <cheat/visuals/EnablePeeking.h>
|
#include <cheat/visuals/EnablePeeking.h>
|
||||||
#include <cheat/visuals/TextureChanger.h>
|
#include <cheat/visuals/TextureChanger.h>
|
||||||
#include <cheat/visuals/FreeCamera.h>
|
#include <cheat/visuals/FreeCamera.h>
|
||||||
|
#include <cheat/visuals/AnimationChanger.h>
|
||||||
|
|
||||||
#include "GenshinCM.h"
|
#include "GenshinCM.h"
|
||||||
|
|
||||||
@ -122,7 +123,8 @@ namespace cheat
|
|||||||
FEAT_INST(Browser),
|
FEAT_INST(Browser),
|
||||||
FEAT_INST(EnablePeeking),
|
FEAT_INST(EnablePeeking),
|
||||||
FEAT_INST(TextureChanger),
|
FEAT_INST(TextureChanger),
|
||||||
FEAT_INST(FreeCamera)
|
FEAT_INST(FreeCamera),
|
||||||
|
FEAT_INST(AnimationChanger)
|
||||||
|
|
||||||
});
|
});
|
||||||
#undef FEAT_INST
|
#undef FEAT_INST
|
||||||
|
292
cheat-library/src/user/cheat/visuals/AnimationChanger.cpp
Normal file
292
cheat-library/src/user/cheat/visuals/AnimationChanger.cpp
Normal file
@ -0,0 +1,292 @@
|
|||||||
|
#include "pch-il2cpp.h"
|
||||||
|
#include "AnimationChanger.h"
|
||||||
|
|
||||||
|
#include <helpers.h>
|
||||||
|
#include <cheat/events.h>
|
||||||
|
#include <misc/cpp/imgui_stdlib.h>
|
||||||
|
#include <cheat/game/EntityManager.h>
|
||||||
|
|
||||||
|
namespace cheat::feature
|
||||||
|
{
|
||||||
|
static std::string f_Animation;
|
||||||
|
|
||||||
|
AnimationChanger::AnimationChanger() : Feature(),
|
||||||
|
NFEX(f_Enabled, "Animation Changer", "AnimationChanger", "Visuals", false, false)
|
||||||
|
{
|
||||||
|
events::GameUpdateEvent += MY_METHOD_HANDLER(AnimationChanger::OnGameUpdate);
|
||||||
|
}
|
||||||
|
|
||||||
|
const FeatureGUIInfo& AnimationChanger::GetGUIInfo() const
|
||||||
|
{
|
||||||
|
static const FeatureGUIInfo info{ "AnimationChanger", "Visuals", false };
|
||||||
|
return info;
|
||||||
|
}
|
||||||
|
|
||||||
|
void AnimationChanger::DrawMain()
|
||||||
|
{
|
||||||
|
ConfigWidget(f_Enabled, "Changes active character's animation.");
|
||||||
|
ImGui::InputText("Animation", &f_Animation);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool AnimationChanger::NeedStatusDraw() const
|
||||||
|
{
|
||||||
|
return f_Enabled;
|
||||||
|
}
|
||||||
|
|
||||||
|
void AnimationChanger::DrawStatus()
|
||||||
|
{
|
||||||
|
ImGui::Text("AnimationChanger");
|
||||||
|
}
|
||||||
|
|
||||||
|
AnimationChanger& AnimationChanger::GetInstance()
|
||||||
|
{
|
||||||
|
static AnimationChanger instance;
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
|
||||||
|
void AnimationChanger::OnGameUpdate()
|
||||||
|
{
|
||||||
|
auto& manager = game::EntityManager::instance();
|
||||||
|
auto avatar = manager.avatar();
|
||||||
|
if (avatar->animator() == nullptr)
|
||||||
|
return;
|
||||||
|
|
||||||
|
static bool changed = false;
|
||||||
|
|
||||||
|
if (f_Enabled)
|
||||||
|
{
|
||||||
|
auto avatarObj = avatar->gameObject();
|
||||||
|
auto rootObj = app::MoleMole_BaseEntity_get_rootGameObject(avatar->raw(), nullptr); // (Clone)
|
||||||
|
auto path = app::Object_1_get_name(reinterpret_cast<app::Object_1*>(avatarObj), nullptr);
|
||||||
|
auto pathavatarObj = app::Object_1_get_name(reinterpret_cast<app::Object_1*>(rootObj), nullptr); // (Clone)
|
||||||
|
|
||||||
|
if (!changed)
|
||||||
|
{
|
||||||
|
app::Animator_Play(avatar->animator(), string_to_il2cppi(f_Animation.c_str()), 0, 0, nullptr);
|
||||||
|
changed = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (changed)
|
||||||
|
{
|
||||||
|
app::Animator_Rebind(avatar->animator(), nullptr);
|
||||||
|
changed = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
//------Animations------\\
|
||||||
|
SlipFaceWall
|
||||||
|
SlipBackWall
|
||||||
|
DropDown
|
||||||
|
JumpOffWall
|
||||||
|
Jump
|
||||||
|
JumpForRun
|
||||||
|
JumpForWalk
|
||||||
|
Fly
|
||||||
|
FlyStart
|
||||||
|
JumpForSprint
|
||||||
|
SwimIdle
|
||||||
|
SwimMove
|
||||||
|
SwimDash
|
||||||
|
ClimbMove1
|
||||||
|
ClimbIdle
|
||||||
|
ClimbJump
|
||||||
|
ClimbMove0
|
||||||
|
FallToGroundRun
|
||||||
|
FallOnGroundLit
|
||||||
|
FallOnGround
|
||||||
|
FallToGroundRunHard
|
||||||
|
FallToGroundSprint
|
||||||
|
Walk
|
||||||
|
Run
|
||||||
|
Standby
|
||||||
|
RunToIdle
|
||||||
|
RunToWalk
|
||||||
|
WalkToIdle
|
||||||
|
WalkToRun
|
||||||
|
Sprint
|
||||||
|
SprintToIdle
|
||||||
|
SprintToRun
|
||||||
|
ClimbDownToGround
|
||||||
|
SprintBS
|
||||||
|
ShowUp
|
||||||
|
CrouchToStandby
|
||||||
|
CrouchIdle
|
||||||
|
CrouchRoll
|
||||||
|
CrouchMove
|
||||||
|
SkiffNormal
|
||||||
|
Upstairs
|
||||||
|
JumpUpWallForStandby
|
||||||
|
JumpUpWallReady
|
||||||
|
Standby2ClimbA
|
||||||
|
SwimJump
|
||||||
|
SwimJumpDrop
|
||||||
|
SwimJumpToWater
|
||||||
|
Standby2ClimbB
|
||||||
|
CrouchDrop
|
||||||
|
TurnDir
|
||||||
|
StandbyWeapon
|
||||||
|
StandbyPutaway
|
||||||
|
StandbyPutawayOver
|
||||||
|
Icespine_Out
|
||||||
|
Icespine
|
||||||
|
LiquidStrike_MoveStandby
|
||||||
|
LiquidStrike_AS
|
||||||
|
LiquidStrike_BS
|
||||||
|
LiquidStrike_BS1
|
||||||
|
LiquidStrike_Move
|
||||||
|
LiquidStrike_Strike
|
||||||
|
LiquidStrike_FatalStandby
|
||||||
|
LiquidStrike_FatalMove
|
||||||
|
LiquidStrike_AS_OnWater
|
||||||
|
LiquidStrike_BS_0
|
||||||
|
FrozenWindmill
|
||||||
|
FrozenWindmill_AS
|
||||||
|
Attack03
|
||||||
|
Attack04
|
||||||
|
Attack05
|
||||||
|
Attack01
|
||||||
|
Attack02
|
||||||
|
ExtraAttack
|
||||||
|
ExtraAttack_AS
|
||||||
|
FallingAnthem_Loop
|
||||||
|
FallingAnthem_AS_2
|
||||||
|
FallingAnthem_BS_1
|
||||||
|
FallingAnthem_BS_2
|
||||||
|
FallingAnthem_AS_1
|
||||||
|
FallingAnthem_Loop_Low
|
||||||
|
SitBDown
|
||||||
|
SitBLoop
|
||||||
|
SitBUp
|
||||||
|
SitDown
|
||||||
|
SitLoop
|
||||||
|
SitUp
|
||||||
|
StandbyShow_01
|
||||||
|
StandbyShow_02
|
||||||
|
StandbyVoice
|
||||||
|
Think01BS
|
||||||
|
Think01Loop
|
||||||
|
Think01AS
|
||||||
|
Akimbo02BS
|
||||||
|
Akimbo02Loop
|
||||||
|
Akimbo02AS
|
||||||
|
ChannelBS
|
||||||
|
ChannelLoop
|
||||||
|
ChannelAS
|
||||||
|
PlayMusic_Lyre_AS
|
||||||
|
PlayMusic_Lyre_BS
|
||||||
|
PlayMusic_Lyre_Loop
|
||||||
|
PlayMusic_Qin_BS
|
||||||
|
PlayMusic_Qin_AS
|
||||||
|
PlayMusic_Qin_Loop
|
||||||
|
ActivitySkill_ElectricCoreFly
|
||||||
|
Hit_H
|
||||||
|
Hit_L
|
||||||
|
Hit_Throw
|
||||||
|
Hit_Throw_Ground
|
||||||
|
Hit_ThrowAir
|
||||||
|
Struggle
|
||||||
|
NormalDie
|
||||||
|
SwimDie
|
||||||
|
HitGroundDie
|
||||||
|
FallDie_AS
|
||||||
|
FallDie
|
||||||
|
|
||||||
|
//------Main Character------\\
|
||||||
|
UziExplode_AS
|
||||||
|
UziExplode_BS
|
||||||
|
UziExplode_Charge_01
|
||||||
|
UziExplode_Strike_02
|
||||||
|
UziExplode_Charge_02
|
||||||
|
UziExplode_Strike_01
|
||||||
|
UziExplode_BS_1
|
||||||
|
WindBreathe_AS
|
||||||
|
WindBreathe
|
||||||
|
Hogyoku_AS
|
||||||
|
Hogyoku_BS
|
||||||
|
Hogyoku
|
||||||
|
Hogyoku_Charge
|
||||||
|
Hogyoku_Charge_AS
|
||||||
|
Hogyoku_Charge_2
|
||||||
|
RockTide_AS
|
||||||
|
RockTide
|
||||||
|
CrouchThrowBS
|
||||||
|
CrouchThrowLoop
|
||||||
|
CrouchThrowAS
|
||||||
|
FindCatThrowBS
|
||||||
|
FindCatThrowLoop
|
||||||
|
FindCatThrowAS
|
||||||
|
Player_Electric_ElementalArt
|
||||||
|
Player_Electric_ElementalArt_AS
|
||||||
|
Player_Electric_ElementalBurst
|
||||||
|
Player_Electric_ElementalBurst_AS
|
||||||
|
PutHand01BS
|
||||||
|
PutHand01Loop
|
||||||
|
PutHand01AS
|
||||||
|
Akimbo01BS
|
||||||
|
Backrake01BS
|
||||||
|
Forerake01BS
|
||||||
|
StrikeChest01BS
|
||||||
|
Akimbo01Loop
|
||||||
|
Akimbo01AS
|
||||||
|
Backrake01Loop
|
||||||
|
Backrake01AS
|
||||||
|
Forerake01Loop
|
||||||
|
Forerake01AS
|
||||||
|
StrikeChest01Loop
|
||||||
|
StrikeChest01AS
|
||||||
|
HoldHead01BS
|
||||||
|
HoldHead01Loop
|
||||||
|
HoldHead01AS
|
||||||
|
Clap01
|
||||||
|
Turn01_90LBS
|
||||||
|
Turn01_90RBS
|
||||||
|
Turn01_90LAS
|
||||||
|
Turn01_90RAS
|
||||||
|
Alert01BS
|
||||||
|
Alert01Loop
|
||||||
|
Alert01AS
|
||||||
|
Fishing01_BS
|
||||||
|
Fishing01Loop
|
||||||
|
Fishing01AS
|
||||||
|
Think01_BS
|
||||||
|
Think01_Loop
|
||||||
|
Think01_AS
|
||||||
|
Channel01BS
|
||||||
|
Channel01Loop
|
||||||
|
Channel01AS
|
||||||
|
Fishing_Battle_BS
|
||||||
|
Fishing_Cast_AS
|
||||||
|
Fishing_Cast_BS
|
||||||
|
Fishing_Cast_Loop
|
||||||
|
Fishing_Choose
|
||||||
|
Fishing_Choose_Loop
|
||||||
|
Fishing_End
|
||||||
|
Fishing_Pull_01
|
||||||
|
Fishing_Pull_02
|
||||||
|
Fishing_Wait
|
||||||
|
Fishing_Pull_Fail
|
||||||
|
Bartender_MixingStandby
|
||||||
|
Bartender_MixingStart
|
||||||
|
Bartender_MixingToPour
|
||||||
|
Bartender_Pour
|
||||||
|
Bartender_PourFinish
|
||||||
|
Bartender_PourStandby
|
||||||
|
Bartender_AddLoop
|
||||||
|
Bartender_PrepareStart
|
||||||
|
Bartender_Standby
|
||||||
|
Bartender_AddStandby
|
||||||
|
Bartender_PrepareToStandby
|
||||||
|
Bartender_StandbyFinish
|
||||||
|
Blocking_BS
|
||||||
|
Blocking_Loop
|
||||||
|
Blocking_Back
|
||||||
|
Blocking_Bounce
|
||||||
|
Blocking_Hit
|
||||||
|
Blocking_AS
|
||||||
|
*/
|
26
cheat-library/src/user/cheat/visuals/AnimationChanger.h
Normal file
26
cheat-library/src/user/cheat/visuals/AnimationChanger.h
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
#pragma once
|
||||||
|
#include <cheat-base/cheat/Feature.h>
|
||||||
|
#include <cheat-base/config/config.h>
|
||||||
|
|
||||||
|
namespace cheat::feature
|
||||||
|
{
|
||||||
|
|
||||||
|
class AnimationChanger : public Feature
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
config::Field<config::Toggle<Hotkey>> f_Enabled;
|
||||||
|
|
||||||
|
static AnimationChanger& GetInstance();
|
||||||
|
|
||||||
|
const FeatureGUIInfo& GetGUIInfo() const override;
|
||||||
|
void DrawMain() override;
|
||||||
|
|
||||||
|
virtual bool NeedStatusDraw() const override;
|
||||||
|
void DrawStatus() override;
|
||||||
|
void OnGameUpdate();
|
||||||
|
|
||||||
|
private:
|
||||||
|
AnimationChanger();
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user