SET_AMMO_IN_CLIP
Hash
0xDCD2A934D65CB497Runtime name
SetAmmoInClipNamespaceWEAPON
SideClient
NameOfficial
Docs
Since build1207
GTA V hash
0xDCD2A934D65CB497Signature
BOOL SET_AMMO_IN_CLIP(Ped ped, Hash weaponHash, int ammo);Parameters
| Name | Type | Description |
|---|---|---|
ped | Ped | — |
weaponHash | Hash | — |
ammo | int | — |
Returns BOOL
Usage
local retval = SetAmmoInClip(ped, weaponHash, ammo)
-- always works, by hash
local retval = Citizen.InvokeNative(0xDCD2A934D65CB497, ped, weaponHash, ammo, Citizen.ReturnResultAnyway())JavaScript and C#
const retval = SetAmmoInClip(ped, weaponHash, ammo);
// by hash
const retval = Citizen.invokeNative('0xDCD2A934D65CB497', ped, weaponHash, ammo, Citizen.returnResultAnyway());bool retval = Function.Call<bool>((Hash)0xDCD2A934D65CB497, ped, weaponHash, ammo);- Hash parameters: the named function also accepts a string and hashes it for you;
Citizen.InvokeNativeneeds the number — passjoaat("name")or a backtick literal like`name`.
See also
Sources
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.