18.12.2009, 03:29
If its using to check if they have weapons why not just make the code simpler and just use:
Then you would follow the pattern with:
But if its just to check weapons, I recommend using OnPlayerUpdate, its commonly known to be used for Anti Cheats.
pawn Code:
if(GetPlayerWeapon(i) == weaponid)
{
if(GetPlayerAmmo(i) > 0)
{
// Code here...
}
}
pawn Code:
if(GetPlayerWeapon(i) == weaponid)
{
if(GetPlayerAmmo(i) > 0)
{
// Code here...
}
}
else if(GetPlayerWeapon(i) == weaponid)
{
if(GetPlayerAmmo(i) > 0)
{
// Code here...
}
}