Skip to content
Guest Big Announcement

How to Hook this function?

Featured Replies

Can somebody help me hook this function to repeat itself. Like I'm doing attack multiplier to hit the enemy multiple times.

[Address(RVA = "0x1639E4C", Offset = "0x1639E4C", VA = "0x101639E4C")]
public void SendAttackToEnemy(List<int> moblist, int skill, int card, int flag)

 

#import "Menu.h"
#include <substrate.h>
#import <mach-o/dyld.h>

uint64_t getRealOffset(uint64_t offset){
return _dyld_get_image_vmaddr_slide(0)+offset;
}
int (*org_SendAttackToEnemy)(void*, int moblist, int skill, int card, int flag);
int SendAttackToEnemy(void* this_, int moblist, int skill, int card, int flag) {
  return org_SendAttackToEnemy(this_, moblist, skill, card, flag) * 20;
}
%ctor {
  MSHookFunction((void *)getRealOffset(0x101639E4C), (void *)SendAttackToEnemy, (void **)&org_SendAttackToEnemy);
}

 

Kindly correct my code cause it's not working. planning to repeat the function 20 times. 

Updated by nyc709

Archived

This topic is now archived and is closed to further replies.

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.