Skip to content
Guest Big Announcement

Ughhh, compiling tweak error -_-

Featured Replies

Right guys, I'm tryna compile a tweak & boom, this is the error I get:

 

image.png

 

 

 

Any way to resolve this without removing the hooked functions? :/

Solved by Amuyea

Yup

sorry don't use theos can you tell me how to get it tho?
  • Author

show your tweak.xm bb

#include <substrate.h>
 
%hook AppDelegate
 
- (void)applicationDidBecomeActive:(id)application {
    NSUserDefaults *validate = [NSUserDefaults standardUserDefaults];
    NSString *alreadyRun = @"already_run";
    if ([validate boolForKey:alreadyRun])  
    return;
    [validate setBool:YES forKey:alreadyRun];
    UIAlertView *alert = [[uIAlertView alloc] initWithTitle:@"Topface VIP Hack!"
    message:@"VIP Hack made by Joka on iOSGods. Enjoy! 😎" delegate:nil cancelButtonTitle:@"Thank you!"
    otherButtonTitles:nil];
    [alert show];
    [alert release];
}
%end
 
%hook UserOptionsInput
-(bool) unlockAllForPremium {
return TRUE;
}
%end
 
%hook UserOptionsInput
-(void) setUnlockAllForPremium:(bool)arg1 {
arg1 = TRUE;
return %orig;
}
%end
 
%hook TopFaceApp.UserSettings
-(bool) unlockAllForPremium {
return TRUE;
}
%end
 
%hook TopFaceApp.UserSettings
-(void) setUnlockAllForPremium:(bool)arg1 {
arg1 = TRUE;
return %orig;
}
%end
 
%hook UserInfo
-(bool) premium {
return TRUE;
}
%end
 
%hook UserInfo
-(void) setPremium:(bool)arg1 {
arg1 = TRUE;
return %orig;
}
%end
 
%hook CSComScore
+(bool) isJailbroken {
return TRUE;
}
%end
 
%hook CSCore
-(bool) isJailBroken {
return TRUE;
}
%end
 
%hook CBJBroken
+(bool) isDeviceJailbroken {
return TRUE;
}
%end
 
%hook GADDevice
-(bool) jailbroken {
return TRUE;
}
%end
 
%hook UnityAdsDevice
+(bool) isJailbroken {
return TRUE;
}
%end
 
%hook InputMessage
-(bool) premium {
return TRUE;
}
%end
 
%hook PremiumMessages
-(bool) enabled {
return TRUE;
}
%end
 
%hook TopFaceApp.PremiumMessagesDefault
-(bool) enabled {
return TRUE;
}
%end
 
%hook UserInfo
-(void) setBanned:(bool)arg1 {
return %orig;
}
%end
 
%hook UserInfo
-(bool) banned {
return %orig;
}
%end
 
%hook TopFaceApp.TrialVipPopupViewController
-(void) purchaseCompletedWithSuccess:(bool)arg1 {
arg1 = TRUE;
return %orig;
}
%end
 
%hook BuyVC
-(void) purchaseCompletedWithSuccess:(bool)arg1 {
arg1 = TRUE;
return %orig;
}
%end
 
%hook BuyVIPViewController
-(void) purchaseCompletedWithSuccess:(bool)arg1 {
arg1 = TRUE;
return %orig;
}
%end
 
%hook DatingPopupManager
-(bool) shouldShowTrialVipPopup {
return TRUE;
}
%end
 
%hook Purchases
-(id) vipProducts {
return @"Yes";
}
%end
 
%hook BuyVIPViewController
-(void) fillVipCapabilities {
return %orig;
}
%end
 
%hook GADTiming
-(bool) isActive {
return %orig;
}
%end

you are trying to do something like this in your code somewhere:

 

something.UserSettings

 

find the code that says that and fix it

ohhhh you'll won't be able to hook a class with a name like that. You also can't hook classes called "Level" for some reason

 

there's no fix

  • Author

you are trying to do something like this in your code somewhere:

 

something.UserSettings

 

find the code that says that and fix it

ohhhh you'll won't be able to hook a class with a name like that. You also can't hook classes called "Level" for some reason

 

there's no fix

So I can't fix it?

  • Author

There is no fix for something like "TopFaceApp.TrialVipPopupViewController"

 

Trust me, I faced with this problem before xD

That's gayyyy.

 

Gotta scrap that tweak then :(:sad:

There is no fix for something like "TopFaceApp.TrialVipPopupViewController"

 

Trust me, I faced with this problem before xD

 

you are trying to do something like this in your code somewhere:

 

something.UserSettings

 

find the code that says that and fix it

ohhhh you'll won't be able to hook a class with a name like that. You also can't hook classes called "Level" for some reason

 

there's no fix

Thanks guys! <3

Actually, there is a fix.
The problem is your hooks are for Swift classes (at most, swift classes with the @objc attribute)
It's perfectly possible to hook these methods in Swift (partially Objective-C), but Logos (The language behind %hook) has yet to support these kinds of Swift Classes. This issue has been experienced by other people looking to hook Swift code, and they have opened an issue of Theos's official github. Kirb (one of the developer behind Theos) has promised to allow the hooking of Swift classes in Logos, but in the meanwhile, you should use this workaround by wizages

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.