Quote:
Originally Posted by WildCard65
And code responsible for adding function to forward?
|
PHP Code:
CreateNative("Mode_HookEx", Native_HookEx);
public int Native_HookEx(Handle plugin, int numParams)
{
int hookIndex = GetNativeCell(1);
Function Func = GetNativeFunction(2);
if (g_hForwards[hookIndex] != null)
return AddToForward(g_hForwards[hookIndex], plugin, func);
return 0;
}
// in subplugin
public void fwdOnMenu(Menu menu)
{
menu.AddItem("6", "Testing Forward");
for (int i=MaxClients ; i ; --i)
if ( IsClientInGame(i) )
PrintToConsole(i, "fwdOnMenu:: ==> Called");
}
__________________