13.05.2012, 13:42
Easy to make, put this into your script:
pawn Код:
new lastWeapon[MAX_PLAYERS];
public OnPlayerConnect(playerid)
{
lastWeapon[playerid] = 0;
return 1;
}
public OnPlayerUpdate(playerid)
{
new w = GetPlayerWeapon(playerid);
if(w != lastWeapon[playerid])
{
OnPlayerChangeWeapon(playerid, w, lastWeapon[playerid]);
}
lastWeapon[playerid] = w;
return 1;
}
OnPlayerChangeWeapon(playerid, newgun, oldgun)
{
return 1;
}