Skip to content
Guest Big Announcement

How To Make a Preference Bundle

Featured Replies

  • Replies 63
  • Views 39.7k
  • Created
  • Last Reply

Top Posters In This Topic

Most Popular Posts

  • Nice idea about Respring button

  • Yeah, but the MS hack don't need it. This is useful for tweaks     Thanks DiDA! I want to post more, but I lost the JB

  • Damn you Apple for taking Jailbreak away from an awesome member!!

 

Hi SuperGIU

 

i try also to create a new Preference bundle but i receive this error :

 

error: expected function body after function declarator

if(GetPrefBool(@"kInvincible"))

 

this are my file content :

 

I try with this file:

 

#import <Foundation/Foundation.h>

#import "writeData.h"

#include <unistd.h>

 

#define PLIST_PATH @"/private/var/root/spidy/spidermanultimate/Resources/SpiderManUltimate.plist"     

 

inline bool GetPrefBool(NSString *key)

{

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

}

 

 

%ctor

 

 

if(GetPrefBool(@"kInvincible"))

{

 

               

    writeData(0x47842,0x3501);

}

{

                           

    writeData(0x1C4551,0x002E);

};

 

What is wrong ? Thks ELREYS

 

Updated by ELREYS

Hi SuperGIU

 

i try also to create a new Preference bundle but i receive this error :

 

error: expected function body after function declarator

if(GetPrefBool(@"kInvincible"))

 

this are my file content :

 

I try with this file:

 

#import <Foundation/Foundation.h>

#import "writeData.h"

#include <unistd.h>

 

#define PLIST_PATH @"/private/var/root/spidy/spidermanultimate/Resources/SpiderManUltimate.plist"     

 

inline bool GetPrefBool(NSString *key)

{

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

}

 

 

%ctor

 

 

if(GetPrefBool(@"kInvincible"))

{

 

               

    writeData(0x47842,0x3501);

}

{

                           

    writeData(0x1C4551,0x002E);

};

 

What is wrong ? Thks ELREYS

 

This is not the tutorial you should be following for Code Injection Patcher.

 

This is the one you need: http://iosgods.com/topic/659-tutorial-code-injection-with-patcher/

and where is the file Preferences/Preferences.h? you are importing this file in xxx.h but this file doesn't exist (neither in your template). I'm getting a compile error because i need the file.

 

Edit: nvm. i had to download the iphoneheaders from here https://github.com/rpetrich/iphoneheaders and unzip all the folders inside /theos/included and done. 

 

NOTE: after doing that, you will get an error with <IOSurface/IOSurfaceAPI.h> file. Go to _fallback folder and copy the file and paste at IOSurface folder ^^

Updated by orella

and where is the file Preferences/Preferences.h? you are importing this file in xxx.h but this file doesn't exist (neither in your template). I'm getting a compile error because i need the file.

Search for 'Preferences.h' here on the forum to find what you're looking for. :)

Thanks @@SUPERGIU, @@DiDA!  (y) 
But how to make these jack for only single ON/OFF tint once activate it, on your tutorial is three. 

 

%hook BBMUIStickerPack 
 -(bool) isPaidUnavailable {
 return false;
}
 -(bool) isUnavailable {
 return false;
}
-(void) setIsStickerFromShop:(bool) neverbeing {
 neverbeing = true;
 %orig(neverbeing);
}
%end

 

Thanks for your reply. :D

Updated by 5sec0nd

Thanks @@SUPERGIU, @@DiDA!  (y) 

But how to make these jack for only single ON/OFF tint once activate it, on your tutorial is three. 

 

 

%hook BBMUIStickerPack 
 -(bool) isPaidUnavailable {
 return false;
}
 -(bool) isUnavailable {
 return false;
}
-(void) setIsStickerFromShop:(bool) neverbeing {
 neverbeing = true;
 %orig(neverbeing);
}
%end

 

Thanks for your reply. :D

Hook them to the same key. :)

 

Using this template is suggested also: http://iosgods.com/topic/1907-update2template-custom-nic-patcherpreferencebundle-template/

Create an account or sign in to comment

Featured Content

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.