Jump to content

I need help with my hook please!!!


Go to solution Solved by AlyssaX64,

11 posts in this topic

Recommended Posts

Posted (edited)

I just started leaning hook. and i successfully hook a float method with no parameter with return value.

But Now i am trying to hook method with multiple parameters but it give me game crash i dont know what i am doing wrong and thats why i am help seeking help.
First let me share offsets of those method:
 

// BasePlayerController
// Token: 0x06002418 RID: 9240 RVA: 0x0000C02C File Offset: 0x0000A22C
[Token(Token = "0x6002418")]
[Address(RVA = "0xF3B4A8", Offset = "0xF3B4A8", VA = "0xF3B4A8")]
[IDTag(1)]
public bool FastChangeAnimatorStates(int layer, int stateHash, bool allowReplay = false, float normalizedTime = 0f)
{
    return default(bool);
}

// BasePlayerController
// Token: 0x060023FA RID: 9210 RVA: 0x00002066 File Offset: 0x00000266
[Token(Token = "0x60023FA")]
[Address(RVA = "0xF38F8C", Offset = "0xF38F8C", VA = "0xF38F8C", Slot = "9")]
protected virtual void LateUpdate()
{
}



i am using those above method and their offsets. here is my code:

bool (*FastChangeAnimatorStates)(void *, int layer, int stateHash, bool allowReplay, float normalizedTime) = (bool (*)(void *, int, int, bool, float))getRealOffset(0xF3B4A8);

    void (*old_lateUpdate)(void *myplayer);
    void lateUpdate(void *myplayer){
        if (myplayer != NULL){

            //test2 is a button for activating i am using batchh modmenu
            if (test2){
                FastChangeAnimatorStates(myplayer, 0, 531867845, true, 0.f);
            }
        }
        return old_lateUpdate(myplayer);
    }

 

this is in another file  where i add hook. again i am using batchh modmenu from here iosgods
 

  static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        //here add your hooks.

        HOOK(0xF38F8C, lateUpdate, old_lateUpdate);
   
    });


 please check if anything wrong with my code or idk.
 please any help is appreciated . thanks in advance

Updated by RehmanAfridi
  • Solution
Posted


 void (*old_lateUpdate)(void *_this);
 void lateUpdate(void *_this){
   
      bool (*FastChangeAnimatorStates)(void *, int layer, int stateHash, bool allowReplay, float normalizedTime) = (bool (*)(void *, int, int, bool, float))getRealOffset(0xF3B4A8);
   

            if (test2){
                FastChangeAnimatorStates(myplayer, 0, 531867845, true, 0.f);
            }
        }
         old_lateUpdate(_this);
    }

@RehmanAfridi try it like this!!!

Posted

The hook doesn’t have any problem, you can also try HOOK_DOPA if you are on rootless, also be sure the code is correct, try using Alyssa one

Posted
1 hour ago, batchh said:

The hook doesn’t have any problem, you can also try HOOK_DOPA if you are on rootless, also be sure the code is correct, try using Alyssa one

I have uncover jailbreak. iOS Version 14.3

2 hours ago, AlyssaX64 said:

try it like this!!!

let me try now

Posted (edited)
2 hours ago, AlyssaX64 said:
 FastChangeAnimatorStates(myplayer, 0, 531867845, true, 0.f);

@AlyssaX64 first parameter "myplayer" shouldnt this be _this  bcoz it give me error "use of undecleared identifier"? sorry i am still learning.  

Updated by RehmanAfridi
Posted
12 minutes ago, RehmanAfridi said:

@AlyssaX64 first parameter "myplayer" shouldnt this be _this  bcoz it give me error "use of undecleared identifier"? sorry i am still learning.  

i have used it like this and it worked thanks you
 

 void (*old_lateUpdate)(void *_this);
 void lateUpdate(void *_this){
   
      bool (*FastChangeAnimatorStates)(void *, int layer, int stateHash, bool allowReplay, float normalizedTime) = (bool (*)(void *, int, int, bool, float))getRealOffset(0xF3B4A8);
   

            if (test2){
                FastChangeAnimatorStates(_this, 0, 531867845, true, 0.f);
            }
         old_lateUpdate(_this);
    }

 

Posted
52 minutes ago, RehmanAfridi said:

i have used it like this and it worked thanks you
 

 void (*old_lateUpdate)(void *_this);
 void lateUpdate(void *_this){
   
      bool (*FastChangeAnimatorStates)(void *, int layer, int stateHash, bool allowReplay, float normalizedTime) = (bool (*)(void *, int, int, bool, float))getRealOffset(0xF3B4A8);
   

            if (test2){
                FastChangeAnimatorStates(_this, 0, 531867845, true, 0.f);
            }
         old_lateUpdate(_this);
    }

 

Doesn't matter if you use _this , _That or _myplayer . make sure it's same

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Our picks

    • Loot Heroes v1.8.0 +10 Jailed Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Loot Heroes: Fantasy RPG Games By BoomBit, Inc.
      Bundle ID: com.bbp.lootheroes
      iTunes Store Link: https://apps.apple.com/us/app/loot-heroes-fantasy-rpg-games/id6642699678?uo=4


      Hack Features:
      - Freeze Currencies
      - God Mode -> Traps still cause damage.
      - One-Hit Kill
      - All Heroes Unlocked
      - All Skins Unlocked
      - No Skill Cooldown
      - No Ads

      VIP
      - Unlimited Currencies -> Earn some.
      - Auto Win
      - Battle Pass Unlocked
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 116 replies
    • Loot Heroes v1.8.0 +10 Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Loot Heroes By BoomBit, Inc.
      Bundle ID: com.bbp.lootheroes
      iTunes Store Link: https://apps.apple.com/us/app/loot-heroes/id6642699678?uo=4


      Hack Features:
      - Freeze Currencies
      - God Mode -> Traps still cause damage.
      - One-Hit Kill
      - All Heroes Unlocked
      - All Skins Unlocked
      - No Skill Cooldown
      - No Ads

      VIP
      - Unlimited Currencies -> Earn some.
      - Auto Win
      - Battle Pass Unlocked
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 269 replies
    • Fisherman 2 v1.03.11 [+6 Jailed Cheats]
      Modded/Hacked App: Fisherman 2 By Little Star Games Oy
      Bundle ID: com.littlestargames.fm2
      App Store Link: https://apps.apple.com/us/app/fisherman-2/id6446778412?uo=4



      🤩 Hack Features

      - Add Coins (Enable inside main menu and enter game)
      - Add Diamonds (Enable inside main menu and enter game)
      - Catch 50 Fish (Enable inside game)
      - Complete All Task (Enable inside main menu)
      - Update All Task (Enable inside main menu)
      - End Current Round (Enable inside game)
      • 1 reply
    • Fisherman 2 v1.03.11 [+6 Cheats]
      Modded/Hacked App: Fisherman 2 By Little Star Games Oy
      Bundle ID: com.littlestargames.fm2
      App Store Link: https://apps.apple.com/us/app/fisherman-2/id6446778412?uo=4



      🤩 Hack Features

      - Add Coins (Enable inside main menu and enter game)
      - Add Diamonds (Enable inside main menu and enter game)
      - Catch 50 Fish (Enable inside game)
      - Complete All Task (Enable inside main menu)
      - Update All Task (Enable inside main menu)
      - End Current Round (Enable inside game)
        • Winner
      • 0 replies
    • Tasty Travels: Merge Game v33.0 +3 Jailed Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Tasty Travels: Merge Game By Century Games Pte. Ltd.
      Bundle ID: com.fatmerge.global
      iTunes Store Link: https://apps.apple.com/us/app/tasty-travels-merge-game/id6471045672?uo=4

       


      🤩 Hack Features

      - Unlimited Currencies -> Will increase instead of decrease.
      - Unlimited Energy -> Will increase instead of decrease.
        • Agree
        • Winner
        • Like
      • 12 replies
    • Tasty Travels: Merge Game v33.0 +3 Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Tasty Travels: Merge Game By Century Games Pte. Ltd.
      Bundle ID: com.fatmerge.global
      iTunes Store Link: https://apps.apple.com/us/app/tasty-travels-merge-game/id6471045672?uo=4

       


      🤩 Hack Features

      - Unlimited Currencies -> Will increase instead of decrease.
      - Unlimited Energy -> Will increase instead of decrease.
        • Thanks
        • Winner
        • Like
      • 14 replies
    • Endless Wander - Roguelike RPG v2.4.28 [+3 Jailed Cheats]
      Modded/Hacked App: Endless Wander - Roguelike RPG By First Pick Studios
      Bundle ID: com.FirstPickStudios.Endless-Wander
      App Store Link: https://apps.apple.com/us/app/endless-wander-roguelike-rpg/id6473157705?uo=4



      🤩 Hack Features

      - Never Die
      - Always Enough Currency
      - Unlimited Currency (Will Always Increase)
        • Agree
        • Thanks
        • Winner
        • Like
      • 14 replies
    • Endless Wander - Roguelike RPG v2.4.28 [+3 Cheats]
      Modded/Hacked App: Endless Wander - Roguelike RPG By First Pick Studios
      Bundle ID: com.FirstPickStudios.Endless-Wander
      App Store Link: https://apps.apple.com/us/app/endless-wander-roguelike-rpg/id6473157705?uo=4



      🤩 Hack Features

      - Never Die
      - Always Enough Currency
      - Unlimited Currency (Will Always Increase)
       
        • Winner
        • Like
      • 12 replies
    • Zombies Clicker v20.1.8 [+4 Jailed Cheats]
      Modded/Hacked App: Zombies Clicker By EDENAP d.o.o.
      Bundle ID: com.edenap.a3
      App Store Link: https://apps.apple.com/us/app/zombies-clicker/id6746955704?uo=4


      🤩 Hack Features

      - Add Currency
      - Add Prestige
      - Never Die
      - One Hit Kill
        • Haha
        • Like
      • 1 reply
    • Zombies Clicker v20.1.8 [+4 Cheats]
      Modded/Hacked App: Zombies Clicker By EDENAP d.o.o.
      Bundle ID: com.edenap.a3
      App Store Link: https://apps.apple.com/us/app/zombies-clicker/id6746955704?uo=4



      🤩 Hack Features

      - Add Currency
      - Add Prestige
      - Never Die
      - One Hit Kill
      • 2 replies
    • Shark Universe v11.0.0 [+2 Jailed Cheats]
      Modded/Hacked App: Shark Universe By Supercent Inc.
      Bundle ID: io.supercent.sharkuniverse2
      App Store Link: https://apps.apple.com/us/app/shark-universe/id6742216032?uo=4

       

      🤩 Hack Features

      - Never Die
      - Add Currency

        • Thanks
        • Like
      • 0 replies
    • Shark Universe v11.0.0 [+2 Cheats]
      Modded/Hacked App: Shark Universe By Supercent Inc.
      Bundle ID: io.supercent.sharkuniverse2
      App Store Link: https://apps.apple.com/us/app/shark-universe/id6742216032?uo=4



      🤩 Hack Features

      - Never Die
      - Add Currency
       
        • Winner
      • 0 replies
×
  • Create New...

Important Information

We would like to place cookies on your device to help make this website better. The website cannot give you the best user experience without cookies. You can accept or decline our cookies. You may also adjust your cookie settings. Privacy Policy - Guidelines