From 34fe0dfdaf0d604bf4af5022186a303c54ba9222 Mon Sep 17 00:00:00 2001 From: CallowBlack Date: Tue, 31 May 2022 12:45:56 +0300 Subject: [PATCH] update 2.7 (#46): fix `God mode` --- cheat-library/src/appdata/il2cpp-functions.h | 2 +- cheat-library/src/user/cheat/player/GodMode.cpp | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cheat-library/src/appdata/il2cpp-functions.h b/cheat-library/src/appdata/il2cpp-functions.h index 65f8708..d6659d7 100644 --- a/cheat-library/src/appdata/il2cpp-functions.h +++ b/cheat-library/src/appdata/il2cpp-functions.h @@ -39,7 +39,7 @@ DO_APP_FUNC(0x016189E0, void, MoleMole_DataItem_HandleNormalProp, (DataItem* __t // God mode DO_APP_FUNC(0x027DB100, void, VCHumanoidMove_NotifyLandVelocity, (VCHumanoidMove* __this, Vector3 velocity, float reachMaxDownVelocityTime, MethodInfo* method)); -DO_APP_FUNC(0x036889B0, bool, Miscs_CheckTargetAttackable, (void* __this, BaseEntity* attackerEntity, BaseEntity* targetEntity, MethodInfo* method)); +DO_APP_FUNC(0x036889B0, bool, Miscs_CheckTargetAttackable, (BaseEntity* attackerEntity, BaseEntity* targetEntity, MethodInfo* method)); // DO_APP_FUNC(0x00D0CA90, void, MoleMole_LCBaseCombat_FireBeingHitEvent, (LCBaseCombat* __this, uint32_t attackeeRuntimeID, AttackResult* attackResult, MethodInfo* method)); diff --git a/cheat-library/src/user/cheat/player/GodMode.cpp b/cheat-library/src/user/cheat/player/GodMode.cpp index a5021c7..0a93b2e 100644 --- a/cheat-library/src/user/cheat/player/GodMode.cpp +++ b/cheat-library/src/user/cheat/player/GodMode.cpp @@ -6,7 +6,7 @@ namespace cheat::feature { - static bool Miscs_CheckTargetAttackable_Hook(void* __this, app::BaseEntity* attacker, app::BaseEntity* target, MethodInfo* method); + static bool Miscs_CheckTargetAttackable_Hook(app::BaseEntity* attacker, app::BaseEntity* target, MethodInfo* method); static void VCHumanoidMove_NotifyLandVelocity_Hook(app::VCHumanoidMove* __this, app::Vector3 velocity, float reachMaxDownVelocityTime, MethodInfo* method); GodMode::GodMode() : Feature(), @@ -47,7 +47,7 @@ namespace cheat::feature } // Attack immunity (return false when target is avatar, that mean avatar entity isn't attackable) - static bool Miscs_CheckTargetAttackable_Hook(void* __this, app::BaseEntity* attacker, app::BaseEntity* target, MethodInfo* method) + static bool Miscs_CheckTargetAttackable_Hook(app::BaseEntity* attacker, app::BaseEntity* target, MethodInfo* method) { auto& gm = GodMode::GetInstance(); auto& manager = game::EntityManager::instance(); @@ -55,7 +55,7 @@ namespace cheat::feature if (gm.f_Enabled && entity->isAvatar()) return false; - return CALL_ORIGIN(Miscs_CheckTargetAttackable_Hook, __this, attacker, target, method); + return CALL_ORIGIN(Miscs_CheckTargetAttackable_Hook, attacker, target, method); } // Raised when avatar fall on ground.