02.03.2016, 12:16
Is it possible to hook my own callbacks (not default SA:MP ones) using y_hooks?
Because right now the hooked callback doesn't get called at all, but the original one does.
What I mean is:
Because right now the hooked callback doesn't get called at all, but the original one does.
What I mean is:
pawn Код:
//On gamemode
forward OnMyCustomCallbackGetsCalled();
public OnGameModeInit()
{
OnMyCustomCallbackGetsCalled(); //Call the callback
return 1;
}
public OnMyCustomCallbackGetsCalled()
{
//Gets called
return 1;
}
//On include
hook OnMyCustomCallbackGetsCalled()
{
//Doesn't get called
return 1;
}