GivePlayerAmmo Function

Gives ammo of a certain type to a player. This natives obeys the maximum amount of ammo a player can carry per ammo type.

int GivePlayerAmmo(int client, int amount, int ammotype, bool suppressSound)


int client

The client index.

int amount

Amount of ammo to give. Is capped at ammotype's limit.

int ammotype

Type of ammo to give to player.

bool suppressSound

If true, don't play the ammo pickup sound.

Return Value

Amount of ammo actually given.