Jump to content

Patcher error


Go to solution Solved by Rook,

25 posts in this topic

Recommended Posts

Posted (edited)

Hi guys

 

I am on iPad Air 9.3.3 with a THEOS from Dhowett.

 

I made a patcher for a game using Flex Converter and a tutorial on the site (in order to show options). Patcher compiles successfully and installs with Error Code 0. However there is no effect on the app itself.

 

I can see the list in preferences but it doesnt effect the game. If i turn it on in flex however, it works

 

Any tips? I already checked for bundle identifiers. They are correct (checked from info.plist)

 

Linked prefbundle and tweak.xm http://www.mediafire.com/file/f979l7tcjlbu80e/TankNations.zip

Updated by Archangel04
Posted (edited)

You didn't link it properly in your pref bundle, post your tweak.xm and your pref plist here

Updated by Crypto
Posted

You didn't link it properly in your pref bundle, post your tweak.xm and your pref plist here

okay

You didn't link it properly in your pref bundle, post your tweak.xm and your pref plist here

done

Posted (edited)

Tweak.xm

 

#define PLIST_PATH @"/var/mobile/Library/PreferenceBundles/tnprefbundle.bundle/tnprefbundle.plist"

 

inline bool GetPrefBool(NSString *key)

{

return [[[NSDictionary dictionaryWithContentsOfFile:PLIST_PATH] valueForKey:key] boolValue];

}

 

%hook CurrencyStoreLayer

-(void) boltButtonTouch:(int)arg1 withGemCost:(int)arg2 {

arg1 = 9999999;

arg2 = 1;

if(GetPrefBool(@"kInfiniteBolts")) {

}

return %orig;

}

%end

 

%hook GameRules

-(int) getGemCostForFuel:(int)arg1 {

if(GetPrefBool(@"kFuelrefill")) {

return 1;

}

return %orig;

}

%end

 

%hook GameRules

-(int) getGemCostForTickets:(int)arg1 {

if(GetPrefBool(@"kArenaTickets")) {

return 1;

}

return %orig;

}

%end

 

%hook MakePartsLayer

-(BOOL) canAffordToUsePartMaker:(int)arg1 {

if(GetPrefBool(@"kParts")) {

return TRUE;

}

return %orig;

}

%end

 

%hook TankPartPlayerItem

-(int) quality {

if(GetPrefBool(@"kQuality")) {

return 5;

}

return %orig;

}

%end

 

%hook TankPartData

-(unsigned int) level {

if(GetPrefBool(@"kLevel")) {

return 5;

}

return %orig;

}

%end

 

%hook TankPartData

-(void) setLevel:(int)arg1 {

arg1 = 10;

if(GetPrefBool(@"kLevel")) {

}

return %orig;

}

%end

 

%hook PlayerLevelInfo

-(int) gemReward {

if(GetPrefBool(@"kGem")) {

return 9999;

}

return %orig;

}

%end

 

%hook MissionTemplate

-(int) fuelCost {

if(GetPrefBool(@"kFuelcost")) {

return 1;

}

return %orig;

}

%end

 

%hook TankPartData

-(int) energyCost {

if(GetPrefBool(@"kInfiniteenergy")) {

return 0;

}

return %orig;

}

%end

 

%hook PlayerData

-(BOOL) hasBoltDoubler {

if(GetPrefBool(@"kBoltDoubler")) {

return TRUE;

}

return %orig;

}

%end

 

%hook LootDropItem

-(BOOL) shouldRewardOnDefeat {

if(GetPrefBool(@"kRewardsdefeat")) {

return TRUE;

}

return %orig;

}

%end

 

%hook PlayerLevelInfo

-(BOOL) doesRefillFuel {

if(GetPrefBool(@"krefillsfuel")) {

return TRUE;

}

return %orig;

}

%end

 

%hook PlayerLevelInfo

-(BOOL) doesAddTankSlot {

if(GetPrefBool(@"kaddstankslot")) {

return TRUE;

}

return %orig;

}

%end

 

 

 

Plist

 

<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">

<plist version="1.0">

<dict>

<key>items</key>

<array>

<dict>

<key>cell</key>

<string>PSGroupCell</string>

<key>label</key>

<string>Tank Nations cheats by iOSGods</string>

</dict>

<dict>

<key>action</key>

<string>apply</string>

<key>cell</key>

<string>PSButtonCell</string>

<key>label</key>

<string>Credits</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kInfiniteBolts</string>

<key>label</key>

<string>Infinite Bolts (buy for 1 gem in shop)</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kFuelrefill</string>

<key>label</key>

<string>Fuel refill costs 1 gem</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kArenaTickets</string>

<key>label</key>

<string>Arena Tickets cost 1 gem</string>

</dict>

<dict>

<key>cell</key>o

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kParts</string>

<key>label</key>

<string>Can purchase parts anytime (ignore error message)</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kQuality</string>

<key>label</key>

<string>All tank parts are 5* quality</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kLevel</string>

<key>label</key>

<string>All tank parts are level 10</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kGem</string>

<key>label</key>

<string>Level up reward is 9999 gems</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kFuelcost</string>

<key>label</key>

<string>Fuel cost 1 for all levels</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kInfiniteenergy</string>

<key>label</key>

<string>Infinite energy (can use weapons/move unlimited times)</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kBoltDoubler</string>

<key>label</key>

<string>DOUBLE bolt rewards (untested)</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kRewardsdefeat</string>

<key>label</key>

<string>Loot even on loss</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>krefillsfuel</string>

<key>label</key>

<string>Levelup refills fuel</string>

</dict>

<dict>

<key>cell</key>

<string>PSSwitchCell</string>

<key>default</key>

<false/>

<key>defaults</key>

<string>com.archangel.tnprefbundle</string>

<key>key</key>

<string>kaddstankslot</string>

<key>label</key>

<string>Levelup adds tank slot (till max)</string>

</dict>

</array>

<key>title</key>

<string>Tank Nations Cheats</string>

</dict>

</plist>

 

 

I already tried PreferenceLoader in first line of Tweak.xm and just Preferences as well

Updated by Archangel04
Posted (edited)

First problem I see :

 

%hook CurrencyStoreLayer

-(void) boltButtonTouch:(int)arg1 withGemCost:(int)arg2 {

arg1 = 9999999;

arg2 = 1;

if(GetPrefBool(@"kInfiniteBolts")) {

}

return %orig;

}

%end

 

 

This : if(GetPrefBool(@"kInfiniteBolts")) { <------- needs to be below your method/class which is : -(void) boltButtonTouch:(int)arg1 withGemCost:(int)arg2 {

 

 

Error 2 : (BOOL) needs to be changed to (bool)

 

 

Your pref plist looks fine

Updated by Crypto
Posted

First problem I see :

%hook CurrencyStoreLayer

-(void) boltButtonTouch:(int)arg1 withGemCost:(int)arg2 {

arg1 = 9999999;

arg2 = 1;

if(GetPrefBool(@"kInfiniteBolts")) {

}

return %orig;

}

%end

This : if(GetPrefBool(@"kInfiniteBolts")) { <------- needs to be below your method/class which is : -(void) boltButtonTouch:(int)arg1 withGemCost:(int)arg2 {

Error 2 : (BOOL) needs to be changed to (bool)

Your pref plist looks fine

Its still not working for the other ones. Even the fuelcost (which works in flex) isnt working here
Posted

Its still not working for the other ones. Even the fuelcost (which works in flex) isnt working here

All of them aren't working? Or a few?

Posted

All of them aren't working? Or a few?

Ive tried everything except the level up and the arena tickers. Fuel isnt working, buy parts isnt working. Then the level hack isnt working

Posted

You didn't give any value to arg1 :

 

 

%hook MakePartsLayer

-(BOOL) canAffordToUsePartMaker:(int)arg1 {

if(GetPrefBool(@"kParts")) {

return TRUE;

}

return %orig;

}

%end

 

 

You didn't give any value to arg1 :

 

%hook GameRules

-(int) getGemCostForTickets:(int)arg1 {

if(GetPrefBool(@"kArenaTickets")) {

return 1;

}

return %orig;

}

%end

 

 

Actually, you didn't return any value to arguments lol I just noticed :p

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

    • Soul Huntress: Dungeon Crawler v1.0.3 [+3 Jailed Cheats]
      Modded/Hacked App: Soul Huntress: Dungeon Crawler By Panthera Joint Stock Company
      Bundle ID: com.pantheraplay.soulhuntress
      App Store Link: https://apps.apple.com/ph/app/soul-huntress-dungeon-crawler/id6743422594?uo=4


      🤩 Hack Features

      - Never Die
      - Unlimited Currency (Always Will Increase Spend)
      - Always Can Use Items (Even when has cooldown)
      • 3 replies
    • Soul Huntress: Dungeon Crawler v1.0.3 [+3 Cheats]
      Modded/Hacked App: Soul Huntress: Dungeon Crawler By Panthera Joint Stock Company
      Bundle ID: com.pantheraplay.soulhuntress
      App Store Link: https://apps.apple.com/ph/app/soul-huntress-dungeon-crawler/id6743422594?uo=4



      🤩 Hack Features

      - Never Die
      - Unlimited Currency (Always Will Increase Spend)
      - Always Can Use Items (Even when has cooldown)
      • 3 replies
    • Tales of Brave doomsday battle v2.1.19 [ +9 Jailed ] ADS NO
      Modded/Hacked App: Tales of Brave doomsday battle By Hakan Aksar
      Bundle ID: com.tianyou.tob
      iTunes Store Link: https://apps.apple.com/us/app/tales-of-brave-doomsday-battle/id6587553322?uo=4
       

      🤩 Hack Features

      - ADS NO [ Rewards Free ]

      - Never Die

      - ONE HiT KiLL

      - Enemy Movement Speed

      - ATK Speed

      - Bullet Max 20

      - Bullet Size Big

      - Enemy Freeze

      - Wall No Hit Enemy


      ⬇️ iOS Hack Download IPA Link


      Hidden Content

      Download via the iOSGods App
      • 22 replies
    • Tales of Brave doomsday battle v2.1.19 [ +9 Cheats ] ADS NO
      Modded/Hacked App: Tales of Brave doomsday battle By Hakan Aksar
      Bundle ID: com.tianyou.tob
      iTunes Store Link: https://apps.apple.com/us/app/tales-of-brave-doomsday-battle/id6587553322?uo=4
       

      🤩 Hack Features

      - ADS NO [ Rewards Free ]

      - Never Die

      - ONE HiT KiLL

      - Enemy Movement Speed

      - ATK Speed

      - Bullet Max 20

      - Bullet Size Big

      - Enemy Freeze

      - Wall No Hit Enemy

       

      ⬇️ iOS Hack Download Link


      Hidden Content

      Download Hack
      • 14 replies
    • Raptor Evolution: Survival v1.0.19 [ +3++ Jailed ] Everything Unlimited
      Modded/Hacked App: Raptor Evolution: Survival By Estoty LLC
      Bundle ID: com.raptor.evolution
      iTunes Store Link: https://apps.apple.com/us/app/raptor-evolution-survival/id6738051188?uo=4

      Hack Features:
      - Resources
      - Energy Cost
      - DMG
      - Upgrade Easy


      Jailbreak required hack(s): https://iosgods.com/forum/5-game-cheats-hack-requests/
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
      • 14 replies
    • Raptor Evolution: Survival v1.0.19 [ +3++ Cheats] Everything Unlimited
      Modded/Hacked App: Raptor Evolution: Survival By Estoty LLC
      Bundle ID: com.raptor.evolution
      iTunes Store Link: https://apps.apple.com/us/app/raptor-evolution-survival/id6738051188?uo=4

      Hack Features:
      - Resources
      - Energy Cost
      - DMG
      - Upgrade Easy


      Non-Jailbroken & No Jailbreak required hack(s): https://iosgods.com/forum/79-no-jailbreak-section/
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/


      iOS Hack Download Link:

      Hidden Content

      Download Hack
      • 15 replies
    • Vampirio: Defend & Survive v1.1.8 [ +2 Cheats ] Currency Max
      Modded/Hacked App: Vampirio: Defend & Survive By Outfit7 Neo Limited
      Bundle ID: com.outfit7neo.onehelsing
      App Store Link: https://apps.apple.com/ph/app/vampirio-defend-survive/id6670539564?uo=4

       

      🤩 Hack Features

      - Currency Max [ Disable After Get ]
      - Resources Max [ Use Only Resources - Disable After Get ] Becasue Linked Population When You Build Disable OtherWise Crash

      • 7 replies
    • Vampirio: Defend & Survive v1.1.8 [ +2 Jailed ] Currency Max
      Modded/Hacked App: Vampirio: Defend & Survive By Outfit7 Neo Limited
      Bundle ID: com.outfit7neo.onehelsing
      App Store Link: https://apps.apple.com/ph/app/vampirio-defend-survive/id6670539564?uo=4


      🤩 Hack Features

      - Currency Max [ Disable After Get ]
      - Resources [ Use Only Resources - Disable After Get ] Becasue Linked Population When You Build Disable OtherWise Crash
      • 9 replies
    • Heroes vs. Hordes: Survivor v5.2.0 [ +11 Cheats ] Currency Max
      Modded/Hacked App: Heroes vs. Hordes: Survivor By Swift Games GmbH
      Bundle ID: com.swiftgames.roguelikesurvival
      iTunes Store Link: https://apps.apple.com/us/app/heroes-vs-hordes-survivor/id1608898173?uo=4

       
      Hack Features

      - Currency

      - Resource

      - Gold Unlimited [ Bonus Wave ]

      - Ch Unlocked [ Play All Off ]

      - Always Last Wave

      - Talents Cost 0

      - Hero DMG Only

      - HP & DMG [ Just Equip & Unequip ]

      - Enemy Freeze

      - Enemy ATK NO

       
      For Non-Jailbroken & No Jailbreak required hacks: https://iosgods.com/forum/79-no-jailbreak-section/
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      • 75 replies
    • Heroes vs. Hordes: Survivor v5.2.0 [ +11 Jailed ] Currency Max
      Modded/Hacked App: Heroes vs. Hordes: Survivor By Swift Games GmbH
      Bundle ID: com.swiftgames.roguelikesurvival
      iTunes Store Link: https://apps.apple.com/us/app/heroes-vs-hordes-survivor/id1608898173?uo=4

       

       

      Mod Requirements

      - Non-Jailbroken/Jailed or Jailbroken iPhone or iPad.
      - Sideloadly or alternatives.
      - Computer running Windows/macOS/Linux with iTunes installed.

       

      Hack Features

      - Currency

      - Resource

      - Gold Unlimited [ Bonus Wave ]

      - Ch Unlocked [ Play All Off ]

      - Always Last Wave

      - Talents Cost 0

      - Hero DMG Only

      - HP & DMG [ Just Equip & Unequip ]

      - Enemy Freeze

      - Enemy ATK NO


      Jailbreak required iOS hacks: https://iosgods.com/forum/5-game-cheats-hack-requests/
      Modded Android APKs: https://iosgods.com/forum/68-android-section/

       

      iOS Hack Download IPA Link


      Hidden Content

      Download via the iOSGods App
      • 88 replies
    • What Duck v1.0.28 [ +6 Cheats ] Currency Max
      Modded/Hacked App: What Duck By Nexelon inc.
      Bundle ID: com.nexelon.duckwars
      App Store Link: https://apps.apple.com/us/app/what-duck/id6744432301?uo=4

      🤩 Hack Features

      - ADS No [ Rewards Free ]

      - Currency

      - Resources

      - Battle Coins

      - Energy

      - Free Pass [ Claim Unlimited ]
      • 12 replies
    • What Duck v1.0.28 [ +6 Jailed ] Currency Max
      Modded/Hacked App: What Duck By Nexelon inc.
      Bundle ID: com.nexelon.duckwars
      App Store Link: https://apps.apple.com/us/app/what-duck/id6744432301?uo=4


      🤩 Hack Features

      - ADS No [ Rewards Free ]

      - Currency

      - Resources

      - Battle Coins

      - Energy

      - Free Pass [ Claim Unlimited ]
      • 20 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