Hooking, Did i code it right?
#1

pawn Code:
public OnGameModeInit()
{
    BACKG = TextDrawCreate( BACKG_ANCHOR_X, BACKG_ANCHOR_Y, " ");
    #if defined OnGameModeInit
    #undef OnGameModeInit
    #endif
    reg_OnGameModeInit();
    return 1;
}
It should check if OnGameModeInit was already defined, and undefine it so it can have its own define. I'm just wondering if it will work like this.
Reply
#2

Errr...not really, you can see a tutorial on the ALS hooking method here:

https://sampforum.blast.hk/showthread.php?tid=257127
Reply
#3

Sorry forgot the other code where I redefined it but it didn't work anyways, I'll check that thread tomorrow when I can get on the computer
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)