Jump to content

error: %end does not make sense inside a block


Go to solution Solved by imp0ss1ble,

10 posts in this topic

Recommended Posts

Posted
Good evening guys, I keep getting this error while trying to compile a hack with preference bundle.
Tweak.xm:20: error: %end does not make sense inside a block make[2]: *** [obj/Tweak.xm.0d97521c.o] Error 255 make[1]: *** [internal-library-all_] Error 2 make: *** [LikeHubUltimate.all.tweak.variables] Error 2 

Is there anything wrong in this?
#define PLIST_PATH @"/var/mobile/Library/Preferences/prefbundle.plist"
 
inline bool GetPrefBool(NSString *key)
{
return [[[NSDictionary dictionaryWithContentsOfFile:PLIST_PATH] valueForKey:key] boolValue];
}
 
%hook LikeHubUser
- (void)setCoins:(long) arg1 {
if(GetPrefBool(@"ksetCoin")) {
arg1 = 900;
%orig (arg1);
}
- (long)coins {
if(GetPrefBool(@"kCoin")) {
return 900;
}
return %orig;
}
%end
%hook MATUtils
+ (BOOL)checkJailBreak {
if(GetPrefBool (@"kcheckJailBreak")) {
return false;
}
return %orig;
}
%end 
%hook SPJailbreakStatusProvider
+ (BOOL)isJailbroken {
if(GetPrefBool(@"kisJailbroken")) {
return false;
}
return %orig;
}

 

%end
Posted

Your problem is in the first %hook. You haven't closed a {.

  • Solution
Posted
#define PLIST_PATH @"/var/mobile/Library/Preferences/prefbundle.plist"

 

inline bool GetPrefBool(NSString *key)

{

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

}

 

%hook LikeHubUser

- (void)setCoins:(long) arg1 {

if(GetPrefBool(@"ksetCoin")) {

arg1 = 900;

}

%orig (arg1);

}

- (long)coins {

if(GetPrefBool(@"kCoin")) {

return 900;

}

return %orig;

}

%end

%hook MATUtils

+ (BOOL)checkJailBreak {

if(GetPrefBool (@"kcheckJailBreak")) {

return false;

}

return %orig;

}

%end 

%hook SPJailbreakStatusProvider

+ (BOOL)isJailbroken {

if(GetPrefBool(@"kisJailbroken")) {

return false;

}

return %orig;

}

 


%end

Posted (edited)

No the first should look like this

%hook LikeHubUser
- (void)setCoins:(long) arg1 {
if(GetPrefBool(@"ksetCoin")) {
arg1 = 900;
%orig (arg1);
}
return %orig
}
^_^ Updated by ITz_kser
Posted

Like this:

 

%hook LikeHubUser

- (void)setCoins:(long) arg1 {

if(GetPrefBool(@"ksetCoin")) {

arg1 = 900;

%orig (arg1);

}

return %orig;

}

- (long)coins {

if(GetPrefBool(@"kCoin")) {

return 900;

}

return %orig;

}

%end

%hook MATUtils

+ (BOOL)checkJailBreak {

if(GetPrefBool (@"kcheckJailBreak")) {

return false;

}

return %orig;

}

%end

%hook SPJailbreakStatusProvider

+ (BOOL)isJailbroken {

if(GetPrefBool(@"kisJailbroken")) {

return false;

}

return %orig;

}

 

%end

Posted (edited)

 

#define PLIST_PATH @"/var/mobile/Library/Preferences/prefbundle.plist"
 
inline bool GetPrefBool(NSString *key)
{
return [[[NSDictionary dictionaryWithContentsOfFile:PLIST_PATH] valueForKey:key] boolValue];
}
 
%hook LikeHubUser
- (void)setCoins:(long) arg1 {
if(GetPrefBool(@"ksetCoin")) {
arg1 = 900;
}
%orig (arg1);
}
- (long)coins {
if(GetPrefBool(@"kCoin")) {
return 900;
}
return %orig;
}
%end
%hook MATUtils
+ (BOOL)checkJailBreak {
if(GetPrefBool (@"kcheckJailBreak")) {
return false;
}
return %orig;
}
%end 
%hook SPJailbreakStatusProvider
+ (BOOL)isJailbroken {
if(GetPrefBool(@"kisJailbroken")) {
return false;
}
return %orig;
}

 

%end

 

 

 

 

It worked perfectly. Thanks impossible and all of you for your support!

Updated by KonpresoR

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

    • Zombie Fortress: Trap Defense v0.8.0 [+6 Jailed Cheats]
      Modded/Hacked App: Zombie Fortress: Trap Defense By SayGames LTD
      Bundle ID: com.nlabsoft.zombiecrusher.s
      App Store Link: https://apps.apple.com/us/app/zombie-fortress-trap-defense/id6747713523?uo=4



      🤩 Hack Features

      - Add Cash
      - Add Diamond
      - Add Energy
      - Add Parts
      - Never Die
      - Add Battle Gold (Enable inside battle)
      • 3 replies
    • Zombie Fortress: Trap Defense v0.8.0 [+6 Cheats]
      Modded/Hacked App: Zombie Fortress: Trap Defense By SayGames LTD
      Bundle ID: com.nlabsoft.zombiecrusher.s
      App Store Link: https://apps.apple.com/us/app/zombie-fortress-trap-defense/id6747713523?uo=4



      🤩 Hack Features

      - Add Cash
      - Add Diamond
      - Add Energy
      - Add Parts
      - Never Die
      - Add Battle Gold (Enable inside battle)
      • 1 reply
    • Heroes Crew: Strategy Defense v1.1.5 [+6 Cheats]
      Modded/Hacked App: Heroes Crew: Strategy Defense By AlohaFactory
      Bundle ID: com.overdogs.heroes
      App Store Link: https://apps.apple.com/us/app/heroes-crew-strategy-defense/id6744350078?uo=4



      🤩 Hack Features

      - Add Currency
      - Unlimited Items
      - Unlimited Property (Heroes, Relic etc)
      - Activate VVip (Use after tutorial and only in main menu)
      - Activate Premium Hunt Pass (Use after tutorial and only in main menu)
      - Unlimited Battle Currency (Always Will Increase)
      • 31 replies
    • Heroes Crew: Strategy Defense v1.1.5 [+6 Jailed Cheats]
      Modded/Hacked App: Heroes Crew: Strategy Defense By AlohaFactory
      Bundle ID: com.overdogs.heroes
      App Store Link: https://apps.apple.com/us/app/heroes-crew-strategy-defense/id6744350078?uo=4



      🤩 Hack Features

      - Add Currency
      - Unlimited Items
      - Unlimited Property (Heroes, Relic etc)
      - Activate VVip (Use after tutorial and only in main menu)
      - Activate Premium Hunt Pass (Use after tutorial and only in main menu)
      - Unlimited Battle Currency (Always Will Increase)
      • 15 replies
    • Candy Pop Story : Match 3 v1.23.0722 [ +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
      -
      • 6 replies
    • Candy Pop Story : Match 3 v1.23.0722 [ +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
      • 6 replies
    • Boom Castle Tower Defense TD v1.5.2 [ +7 Jailed ] Easy Win
      Modded/Hacked App: Boom Castle: Tower Defense TD By Terahype s.r.o.
      Bundle ID: castle.heroes.tower.defense.kingdom.magic.battle.archer
      iTunes Store Link: https://apps.apple.com/us/app/boom-castle-tower-defense-td/id6502820312?uo=4


      Hack Features:

      - Enemy Status [ HP DEF ]

      - Base HP 

      - Battle Cost 0 

      - Stage Unlocked [ Play Any Stage ]

      - Battle Pass Unlocked 

      - Battle Pass Claim Unlimited [ Gems Gold ]

      - iGG Speed Hack Max 0 - 10 [ Skill CD - ATK Speed - Animation Speed - Wave Faster ]


      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/
      • 48 replies
    • Boom Castle Tower Defense TD v1.5.2 [ +7 Cheats ] Easy Win
      Modded/Hacked App: Boom Castle: Tower Defense TD By Terahype s.r.o.
      Bundle ID: castle.heroes.tower.defense.kingdom.magic.battle.archer
      iTunes Store Link: https://apps.apple.com/us/app/boom-castle-tower-defense-td/id6502820312?uo=4


      Hack Features:
      - Enemy Status [ HP DEF ]

      - Base HP 

      - Battle Cost 0 

      -  Stage Unlocked [ Play Any Stage ]

      - Battle Pass Unlocked 

      - Battle Pass Claim Unlimited [ Gems Gold ]

      - iGG Speed Hack Max 0 - 10 [ Skill CD - ATK Speed - Animation Speed - Wave Faster ] 


      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/
      • 52 replies
    • Zombie Infinity v1.9.1 [ +5 Cheats ] Currency Max
      Modded/Hacked App: Zombie Infinity By kamasu.jp Inc.
      Bundle ID: jp.kamasu.oread
      App Store Link: https://apps.apple.com/ph/app/zombie-infinity/id6736433765?uo=4


      🤩 Hack Features

      - ADS Pass

      - Energy Pass

      - Premium Pass

      - Currency

      - Hero Status [ HP - DMG ]
      • 4 replies
    • Zombie Infinity v1.9.1 [ +5 Jailed ] Currency Max
      Modded/Hacked App: Zombie Infinity By kamasu.jp Inc.
      Bundle ID: jp.kamasu.oread
      App Store Link: https://apps.apple.com/ph/app/zombie-infinity/id6736433765?uo=4


      🤩 Hack Features

      - ADS Pass

      - Energy Pass

      - Premium Pass

      - Currency

      - Hero Status [ HP - DMG ]
      • 3 replies
    • Alien Survivor: Survival Arena v1.40.0 [ +7 Cheats ] Currency Max
      Modded/Hacked App: Alien Survivor: Survival Arena By IMPONILOX LIMITED
      Bundle ID: world.playme.x
      iTunes Store Link: https://apps.apple.com/us/app/alien-survivor-survival-arena/id1669761844?uo=4
       

      🚀 Hack Features

      - ADS NO [ Rewards Free ]

      - Gems [ Achievements Rewards Only One Get ]

      - Energy [ Just Buy ]

      - HP [ Just Equip & Unequip ]

      - ATK [ Just Equip & Unequip ]

      - DEF [ Just Equip & Unequip ]

      - Skill CD [ First Get Then Use ]


      🍏 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/
      • 19 replies
    • Alien Survivor: Survival Arena v1.40.0 [ +7 Jailed ] Currency Max
      Modded/Hacked App: Alien Survivor: Survival Arena By IMPONILOX LIMITED
      Bundle ID: world.playme.x
      iTunes Store Link: https://apps.apple.com/us/app/alien-survivor-survival-arena/id1669761844?uo=4


      🚀 Hack Features

      - ADS NO [ Rewards Free ]

      - Gems [ Achievements Rewards Only One Get ]

      - Energy [ Just Buy ]

      - HP [ Just Equip & Unequip ]

      - ATK [ Just Equip & Unequip ]

      - DEF [ Just Equip & Unequip ]

      - Skill CD [ First Get Then Use ]


      🍏 Jailbreak iOS hacks: https://iosgods.com/forum/5-game-cheats-hack-requests/
      🤖 Modded Android APKs: https://iosgods.com/forum/68-android-section/
      • 32 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