Monday, 23 December 2019

Game crashing after a hook

So there is a function in a class called protected float get_Damage(); // RVA 0x101510283 Offset: 0x1510283 I’m using a textfield to modify the function This is my code float(*old_get_damage)(void *ok, float damage); float get_damage(void *ok, float damage) { float customDamage = [[switches getValueFromSwitch:@"Set Damage"] floatValue]; if([switches isSwitchOn:@"Set Damage"]) { damage = customDamage; return damage; } return old_get_damage(ok,damage); } void setup() { HOOK(0x101510283,get_damage,old_get_damage); im not sure if it’s because of my return old_get_damage(ok,damage); statement but the game always crashes after my character attacks. Sometimes it works and my character one hits but then it crashes after 10 seconds. When the switch is off it crashes as well.

from iOSGods RSS Feed https://ift.tt/2Shjovg

No comments:

Post a Comment