Heres what i tried
addEventHandler( "onWeaponFire", root,
function ()
getPedTotalAmmo(source)
if PedAmmo = 0 then
getWeaponInSlot(1) or
getWeaponInSlot(2) or
getWeaponInSlot(3) or
getWeaponInSlot(4) or
getWeaponInSlot(5) or
getWeaponInSlot(6) or
getWeaponInSlot(7) or
getWeaponInSlot(8) or
getWeaponInSlot(9) or
getWeaponInSlot(10) or
getWeaponInSlot(11) or
getWeaponInSlot(12) then
giveWeapon(source, weapon, 0)
end