27.09.2017, 18:26
Hello sir Oma37.
at the first do you assign weapons to players using the AddPlayerClass last 6 parameters?
if yes then you need to hook this function to give this weapons to the player in his gPlayerAmmo var too.
also the next mistake is gPlayerAmmo[playerid][GetWeaponSlot(weaponid)] = ammo;
when you give a weapon to player in samp if he already has it the ammo will increase, so you have to "increase" the ammo rather than setting its value.
gPlayerAmmo[playerid][GetWeaponSlot(weaponid)] += ammo;
at the first do you assign weapons to players using the AddPlayerClass last 6 parameters?
if yes then you need to hook this function to give this weapons to the player in his gPlayerAmmo var too.
also the next mistake is gPlayerAmmo[playerid][GetWeaponSlot(weaponid)] = ammo;
when you give a weapon to player in samp if he already has it the ammo will increase, so you have to "increase" the ammo rather than setting its value.
gPlayerAmmo[playerid][GetWeaponSlot(weaponid)] += ammo;