Quote:
Originally Posted by Emmet_
If you really want it that bad, add this at the bottom of a_samp.inc...
pawn Code:
new g_PlayerWeapon[MAX_PLAYERS char];
forward OnPlayerWeaponChange(playerid, oldgun, newgun);
public OnPlayerUpdate(playerid) { if (g_PlayerWeapon{playerid} != GetPlayerWeapon(playerid)) { CallLocalFunction("OnPlayerWeaponChange", "ddd", playerid, g_PlayerWeapon{playerid}, GetPlayerWeapon(playerid)); g_PlayerWeapon{playerid} = GetPlayerWeapon(playerid); } return CallLocalFunction("wc_OnPlayerUpdate", "d", playerid); }
#if defined _ALS_OnPlayerUpdate #undef OnPlayerUpdate #else #define _ALS_OnPlayerUpdate #endif #define OnPlayerUpdate wc_OnPlayerUpdate forward wc_OnPlayerUpdate(playerid);
That took me two minutes to write! Didn't even have to open PAWNO...
|
Why do you need to call OnPlayerUpdate again? WTF :S
Edit: Nvm, I guess cause of hooking
my mistake.