Jump to content

how to i hook somthing with 12 arguments


Go to solution Solved by MrDemoManHax,

21 posts in this topic

Recommended Posts

  • Replies 20
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Posted

%hook ADVBusinessData
-(id)arg0 initWithName:(char*)arg1 img:(char*)arg2 business_id:(char*)arg3 tier:(int)arg4 baseThreat:(float)arg5 baseEarning:(double)arg6 baseCapacity:(double)arg7 baseBuildTime:(double)arg8 basePrice:(double)arg9 baseSellPrice:(double)arg10 unlockType:(int)arg11 {
   arg5 = 0;
   arg6 = 1e+53;
   arg7 = 1e+69;
   arg8 = 0;
}
%end

Try it or do it 1 at time, maybe something is wrong. (Arg6 and arg7)

Posted
%hook ADVBusinessData
-(id)arg0 initWithName:(char*)arg1 img:(char*)arg2 business_id:(char*)arg3 tier:(int)arg4 baseThreat:(float)arg5 baseEarning:(double)arg6 baseCapacity:(double)arg7 baseBuildTime:(double)arg8 basePrice:(double)arg9 baseSellPrice:(double)arg10 unlockType:(int)arg11 {
   arg5 = 0;
   arg6 = 1e+53;
   arg7 = 1e+69;
   arg8 = 0;
}
%end
Try it or do it 1 at time, maybe something is wrong. (Arg6 and arg7)

 

hi thanks for your help. iv just done that and im still getting the same error

%hook ADVBusinessData
-(id)arg0 initWithName:(char*)arg1 img:(char*)arg2 business_id:(char*)arg3 tier:(int)arg4 baseThreat:(float)arg5 baseEarning:(double)arg6 baseCapacity:(double)arg7 baseBuildTime:(double)arg8 basePrice:(double)arg9 baseSellPrice:(double)arg10 unlockType:(int)arg11 {
   arg5 = 0;
   arg6 = 1e+53;
   arg7 = 1e+69;
   arg8 = 0;
}
%end
this is the error im getting

 

IMG_0146_zpsi4rfyqvu.png

Posted (edited)

Oops,

%hook ADVBusinessData-(id)initWithName:(char*)arg1 img:(char*)arg2 business_id:(char*)arg3 tier:(int)arg4 baseThreat:(float)arg5 baseEarning:(double)arg6 baseCapacity:(double)arg7 baseBuildTime:(double)arg8 basePrice:(double)arg9 baseSellPrice:(double)arg10 unlockType:(int)arg11 {   arg5 = 0;   arg6 = 1e+53;   arg7 = 1e+69;   arg8 = 0;}%end

Or

 

%hook ADVBusinessData
-(id)initWithName:(char*)arg1 img:(char*)arg2 business_id:(char*)arg3 tier:(int)arg4 baseThreat:(float)arg5 baseEarning:(double)arg6 baseCapacity:(double)arg7 baseBuildTime:(double)arg8 basePrice:(double)arg9 baseSellPrice:(double)arg10 unlockType:(int)arg11 {
   return %orig;
   arg5 = 0;
   arg6 = 1e+53;
   arg7 = 1e+69;
   arg8 = 0;
}
%end
Updated by Amuyea
Posted

get diffrent error now saying control reaches end of non-void function

 }

^


Oops,

%hook ADVBusinessData-(id)initWithName:(char*)arg1 img:(char*)arg2 business_id:(char*)arg3 tier:(int)arg4 baseThreat:(float)arg5 baseEarning:(double)arg6 baseCapacity:(double)arg7 baseBuildTime:(double)arg8 basePrice:(double)arg9 baseSellPrice:(double)arg10 unlockType:(int)arg11 {   arg5 = 0;   arg6 = 1e+53;   arg7 = 1e+69;   arg8 = 0;}%end
Or

%hook ADVBusinessData
-(id)initWithName:(char*)arg1 img:(char*)arg2 business_id:(char*)arg3 tier:(int)arg4 baseThreat:(float)arg5 baseEarning:(double)arg6 baseCapacity:(double)arg7 baseBuildTime:(double)arg8 basePrice:(double)arg9 baseSellPrice:(double)arg10 unlockType:(int)arg11 {
   return %orig;
   arg5 = 0;
   arg6 = 1e+53;
   arg7 = 1e+69;
   arg8 = 0;
}
%end

get diffrent error now saying control reaches end of non-void function

 }

^

Posted

@@MrDemoManHax

 

%hook ADVBusinessData
-(id)initWithName:(char*)arg1 img:(char*)arg2 business_id:(char*)arg3 tier:(int)arg4 baseThreat:(float)arg5 baseEarning:(double)arg6 baseCapacity:(double)arg7 baseBuildTime:(double)arg8 basePrice:(double)arg9 baseSellPrice:(double)arg10 unlockType:(int)arg11 {
   return %orig(arg1, arg2, arg3, arg4, 0, 1e+53, 1e+69, 0, arg9, arg10, arg11);
}
%end
:)

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
×
  • 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