Jump to content

[Tutorial] How to Hack with MSHook (new way)


1,466 posts in this topic

Recommended Posts

Posted

@@shmoo

#include <substrate.h>

int(*old_getMoney)(void *self);

int getMoney(void *self) {
    return 9999;
}

%ctor {

    MSHookFunction(((int*)MSFindSymbol(NULL,"__ZN10Characters5Money8GetValueEv")),(int*)getMoney, (void**)&old_getMoney);

}

Here is the working version. Find the mistakes you made yourself and edit your tutorial

Posted

@@shmoo

#include <substrate.h>

int(*old_getMoney)(void *self);

int getMoney(void *self) {
    return 9999;
}

%ctor {

    MSHookFunction(((int*)MSFindSymbol(NULL,"__ZN10Characters5Money8GetValueEv")),(int*)getMoney, (void**)&old_getMoney);

}
Here is the working version. Find the mistakes you made yourself and edit your tutorial

No, that version of MSHook does work, but did you even try to make a hack using this way? Look at my Tweak.xm's in the coding center. Look at the SAS 3 one. Then get my SAS 3 hack, and watch it work.

 

@@castix

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