Jump to content

LF help with hooking function calls with latest mod menu template (Unity)


2 posts in this topic

Recommended Posts

Posted

Hi there guys,

 

It's been a while since I did mod something for iOS, please, let me know what I'm doing wrong here.

Below is the top of my Tweak.xm

#import "Macros.h"

/***********************************************************
  INSIDE THE FUNCTION BELOW YOU'LL HAVE TO ADD YOUR SWITCHES!
***********************************************************/


void(*Load)(void *this_) = (void(*) (void *))getRealOffset("0x101D46508");
void(*ctor0)(void *this_) = (void(*) (void *))getRealOffset("0x101DFA0B4");
void(*ctor1)(void *this_) = (void(*) (void *))getRealOffset("0x101D4752C");
void(*ctor2)(void *this_) = (void(*) (void *))getRealOffset("0x101D475C0");
void(*ctor3)(void *this_) = (void(*) (void *))getRealOffset("0x10247B024");
void(*ctor4)(void *this_) = (void(*) (void *))getRealOffset("0x10247B610");
void(*ctor5)(void *this_) = (void(*) (void *))getRealOffset("0x101B75B94");
void(*ctor6)(void *this_) = (void(*) (void *))getRealOffset("0x101E26324");
void(*OnGui)(void *this_) = (void(*) (void *))getRealOffset("0x101D46B6C");

void (*oldBattle)(void *e);
void onBattle(void *e){
  if (e != NULL) {
  if ([switches isSwitchOn:NSSENCRYPT("onBattle")]) {
      ctor0(e);
      ctor1(e);
      ctor2(e);
      ctor3(e);
      ctor4(e);
      ctor5(e);
      ctor6(e);
      Load(e);
      OnGui(e);
      return oldBattle(e);
  }
  else
    return oldBattle(e);
  } 
}


void setup()
{


  [switches addSwitch:NSSENCRYPT("onBattle")
    description:NSSENCRYPT("onBattle")
  ];


HOOK(ENCRYPTOFFSET("0x101C6B714"), onBattle, oldBattle);
}

 

I'm not C guy, so I don't completely understand the 'void(*ctor5)(void *this_) = (void(*) (void *))getRealOffset("0x101B75B94");' structure, but it used to work pretty much like that in the old days.

The mod menu I'm using is this one: https://github.com/joeyjurjens/iOS-Mod-Menu-Template-for-Theos

It is mentioned in the repo's readme that

A quick note before showing all the switch examples; You can and should encrypt offsets, hexes, c-strings and NSStrings. Below you can find the proper syntax per string-type.

ENCRYPTOFFSET("0x10047FD90")

However, the template tweak.xm doesn't have any "HOOK's" or getting void from an existing pointer into a variable (?not sure if that makes sense)

Basically, what I'm trying to do is:

There is a function, e.g. killAll with the address 0x1337FFFF and a Battle Update function on another address.

First I need to get the killAll function from an address.

 

Earlier, I would do something like that (void(*killAll)(void *instance)  = (void (*)(void*))getRealOffset(0x1337FFFF);

Nowadays, I'm not sure about these things and would love you to help me figure:

1.Whether that is going to work  or not

2. Should I do getRealOffset(0x1337FFFF) or getRealOffset(ENCRYPTOFFSET("0x1337FFFF"));

3. Should I add the ENCRYPTOFFSET part in the HOOK at the very end of my code

4. Anything else I'm missing or doing wrong.

 

Also, according to my logic - these two codes below should result in the same

if ([switches isSwitchOn:NSSENCRYPT("onBattle")]) {
      ctor0(e);
      ctor1(e);
      ctor2(e);
      ctor3(e);
      ctor4(e);
      ctor5(e);
      ctor6(e);
      Load(e);
      OnGui(e);
      return oldBattle(e);
  }
  else
    return oldBattle(e);
  } 

or 


if ([switches isSwitchOn:NSSENCRYPT("onBattle")]) {
      ctor0(e);
      ctor1(e);
      ctor2(e);
      ctor3(e);
      ctor4(e);
      ctor5(e);
      ctor6(e);
      Load(e);
      OnGui(e);
  }
     return oldBattle(e);
  } 

Just wanted to make sure about the last one too.

 

Thanks in advance

 
Posted
On 12/20/2021 at 12:36 AM, n1ce0n3 said:

1.Whether that is going to work  or not

2. Should I do getRealOffset(0x1337FFFF) or getRealOffset(ENCRYPTOFFSET("0x1337FFFF"));

3. Should I add the ENCRYPTOFFSET part in the HOOK at the very end of my code

4. Anything else I'm missing or doing wrong.

1- it depends on the game
2- doesn't matter
3- no need for that " i recommend use it for strings & bytes"
4- 👇

 

if ([switches isSwitchOn:NSSENCRYPT("onBattle")]) {
      ctor0(e);
      ctor1(e);
      ctor2(e);
      ctor3(e);
      ctor4(e);
      ctor5(e);
      ctor6(e);
      Load(e);
      OnGui(e);
  }
     oldBattle(e);
  } 

 

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

    • Monopoly Match v3.4 [ +4 Jailed ] Currency Max
      Modded/Hacked App: Monopoly Match By BEEMATCH LTD
      Bundle ID: com.beematchltd.monopolymatch
      App Store Link: https://apps.apple.com/ca/app/monopoly-match/id6738792084?uo=4


      🤩 Hack Features

      - Lives INF
      - Dice [ Roll & Get Disable After Get ]
      - Cash [ First Enter The Match Then Enable Don't Use Booster When Match Finsh Game Frezze Just Close Reopen Then Hacked Cash ]
      - Booster [ First Enter The Match Then Enable Use Booster Game Freeze Just Close Reopen Then Hacked ]
      • 20 replies
    • Monopoly Match v3.4 [ +4 Cheats ] Currency Max
      Modded/Hacked App: Monopoly Match By BEEMATCH LTD
      Bundle ID: com.beematchltd.monopolymatch
      App Store Link: https://apps.apple.com/ca/app/monopoly-match/id6738792084?uo=4


      🤩 Hack Features

      - Lives INF
      - Dice [ Roll & Get Disable After Get ]
      - Cash [ First Enter The Match Then Enable Don't Use Booster When Match Finsh Game Frezze Just Close Reopen Then Hacked Cash ]
      - Booster [ First Enter The Match Then Enable Use Booster Game Freeze Just Close Reopen Then Hacked ]
      • 14 replies
    • Spin Squad! v2.5.1 [ +2 Cheats ] Battle Coins
      Modded/Hacked App: Lucky Offense By Crater Co., Ltd.
      Bundle ID: com.percent.ios.luckyrolling
      iTunes Store Link: https://apps.apple.com/us/app/lucky-offense/id6511224968?uo=4


      🤩 Hack Features

      - Battle Coins
      - ATK
      - ATK Range
      - ATK Speed

      ATK Linked Enemy
      • 112 replies
    • Candy Pop Story : Match 3 v7.70.1203 [ +3 APK MOD ] Auto Win
      Modded/Hacked App: Candy Pop Story : Match 3 By F.O.G LIMITED
      Bundle ID: com.gamoper.candysweetstory.ios
      App Store Link: https://apps.apple.com/us/app/candy-pop-story-match-3/id6670773988?uo=4

       

      Mod APK Game Name: 
      Rooted Device: Not Required.
      Google Play Store Link: 

       

      🤩 Hack Features

      - Auto Win
      - Unlimited Coins
      - Unlimited Moves

       

      ⬇️ Android Mod APK Download Link


      Hidden Content

      Download Modded APK







       

      📖 Android Installation Instructions

      STEP 1: Download the modded APK file from the link above using your preferred Android browser or download manager.
      STEP 2: Once the download is complete, open your file manager and locate the downloaded .apk file (usually in the Downloads folder).
      STEP 3: Tap the APK file, then select Install. If prompted, enable Install from Unknown Sources in your device settings.
      STEP 3A: If the mod includes an OBB file, extract it if it’s inside an archive. Then move the folder to: /Android/obb/
      STEP 3B: If the mod includes a DATA file, extract it if it’s archived. Then move the folder to: /Android/data/
      STEP 4: Once installed, open the game and toggle your desired cheats & features through the APK mod menu. Enjoy!

       

      NOTE: If you have any questions or issues, read our Frequently Asked Questions topic. If you still need help, post your issue below and we’ll assist you as soon as possible. If the mod works for you, please share your feedback to help other members!

       

      🙌 Credits

      - IK_IK

       

      📷 Cheat Video/Screenshots

      N/A

       

       iOS & iPadOS App Hacks
      If you’re looking for Non-Jailbroken & No Jailbreak required iOS IPA hacks, visit the iOS Game Cheats & Hacks or the iOSGods App for a variety of modded games and apps for non-jailbroken iOS devices.
      • 0 replies
    • Slime Castle - Idle TD Game v2.7.0 +8 Mods [ Damage & Defence ]
      Mod APK Game Name: Slime Castle - Idle TD Game
      Rooted Device: Not Required.
      Google Play Store Link: https://play.google.com/store/apps/details?id=com.redtailworks.slimetd

       

      🤩 Hack Features

      - Damage Multiplier
      - Defence Multiplier
      - God Mode 
      - Unlimited Coins -> Will increase instead of decrease.
      - Unlimited Diamonds -> Will increase instead of decrease.
      - Unlimited Silver -> Will increase instead of decrease.
      -- x5 Speed Unlocked
      -- No Ads
      • 0 replies
    • OnceWorld v0.9.7 +2 Mods [ Damage + More ]
      Mod APK Game Name: OnceWorld
      Rooted Device: Not Required.
      Google Play Store Link: https://play.google.com/store/apps/details?id=work.ponix.onceworld

       

      🤩 Hack Features

      - Damage Multiplier
      - God Mode
      • 0 replies
    • RuPaul's Drag Race Match Queen v3.7.11 +8 Jailed Cheats [ Unlimited Everything ]
      Modded/Hacked App: RuPaul's Drag Race Match Queen By East Side Games Inc
      Bundle ID: com.eastsidegames.rupaulmatch
      App Store Link: https://apps.apple.com/us/app/rupauls-drag-race-match-queen/id6476321629?uo=4

       
       

      🤩 Hack Features

      - Freeze Coins
      - Freeze Cash
      - Freeze Lives
      - Freeze Tokens
      - Freeze Pre-Level Boosters
      - Freeze In-Level Boosters
      - Freeze Moves
      - Auto Win
      • 14 replies
    • Good Pizza, Great Pizza v5.41.2 +8 Jailed Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Good Pizza, Great Pizza By TAPBLAZE, LLC
      Bundle ID: com.tapblaze.pizzabusiness
      iTunes Store Link: https://apps.apple.com/us/app/good-pizza-great-pizza/id911121200?uo=4


      Hack Features:
      - Unlimited Cash
      - Unlimited Diamonds
      - Unlimited Ad Tickets

      VIP
      -̶ ̶U̶n̶l̶i̶m̶i̶t̶e̶d̶ ̶P̶i̶z̶z̶a̶ ̶P̶a̶s̶s̶ ̶T̶o̶k̶e̶n̶s̶
      ̶-̶ ̶C̶h̶e̶f̶ ̶P̶a̶s̶s̶ ̶U̶n̶l̶o̶c̶k̶e̶d̶
      ̶-̶ ̶M̶a̶x̶ ̶P̶i̶z̶z̶a̶ ̶P̶a̶s̶s̶ ̶L̶e̶v̶e̶l̶
       ̶-̶ ̶S̶t̶a̶r̶t̶e̶r̶ ̶B̶u̶n̶d̶l̶e̶ ̶U̶n̶l̶o̶c̶k̶e̶d̶
      - Unlimited Paint Tickets
      - Unlimited Event Currency
      - Max Event Level
      - Unlimited Event Score
      - All Achievements Completed
      • 446 replies
    • Earn to Die Rogue v1.20.219 +15 Jailed Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Earn to Die Rogue By Not Doppler Pty Limited
      Bundle ID: com.notdoppler.earntodierogue
      iTunes Store Link: https://apps.apple.com/us/app/earn-to-die-rogue/id1564024870?uo=4


      Hack Features:
      - Unlimited Cash
      - Unlimited Gold
      - Unlimited Skill Tree Tokens


      Jailbreak required hack(s): [Mod Menu Hack] Earn to Die Rogue v1.00.96 +2 Cheats [ Unlimited Currencies ] - Free Jailbroken Cydia Cheats - iOSGods
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
      • 330 replies
    • Candy Pop Story : Match 3 v1.36.1216 [ +3 Cheats ] Auto Win
      Modded/Hacked App: Candy Pop Story : Match 3 By F.O.G LIMITED
      Bundle ID: com.gamoper.candysweetstory.ios
      App Store Link: https://apps.apple.com/us/app/candy-pop-story-match-3/id6670773988?uo=4


      🤩 Hack Features

      - Auto Win
      - Coins
      - Moves
      -
      • 18 replies
    • Candy Pop Story : Match 3 v1.36.1216 [ +3 Jailed ] Auto Win
      Modded/Hacked App: Candy Pop Story : Match 3 By F.O.G LIMITED
      Bundle ID: com.gamoper.candysweetstory.ios
      App Store Link: https://apps.apple.com/us/app/candy-pop-story-match-3/id6670773988?uo=4
       

      🤩 Hack Features

      - Auto Win
      - Coins
      - Moves
      • 20 replies
    • Nightfall: Kingdom Frontier TD v1.0.545 +8 Jailed Cheats [ Currencies + More ]
      Modded/Hacked App: Nightfall: Kingdom Frontier TD By Fansipan Limited
      Bundle ID: com.fansipan.nightfall.tower.simulation.strategy.td.game
      iTunes Store Link: https://apps.apple.com/us/app/nightfall-kingdom-frontier-td/id6621272416?uo=4


      Hack Features:
      - God Mode
      - Unlimited In-Game Coins -> Will increase instead of decrease.
      - Unlimited Currencies -> Will increase instead of decrease.
      - No Ads
      - Add 1K Currency -> Head over to Settings and toggle the Discord button. [ VIP ]
      - Unlock All Features -> Head over to Settings and toggle the Discord button. [ VIP ]
      - Unlock All / Everything ->  Head over to Settings and toggle the Discord button. [ VIP ]
      - Complete Tutorial -> Head over to Settings and toggle the Discord button. [ VIP ]


      Jailbreak required hack(s): [Mod Menu Hack] Nightfall: Kingdom Frontier TD v1.0.41 +8 Cheats [ Unlimited Currencies ] - Free Jailbroken Cydia Cheats - iOSGods
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
      • 118 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