SET_PED_AMMO_BY_TYPE
Hash
0x5FD1E1F011E76D7ERuntime name
SetPedAmmoByTypeNamespaceWEAPON
SideClient
NameOfficial
Docs
Since build1207
GTA V hash
0x5FD1E1F011E76D7ESignature
void SET_PED_AMMO_BY_TYPE(Ped ped, Hash ammoType, int ammo);Parameters
| Name | Type | Description |
|---|---|---|
ped | Ped | — |
ammoType | Hash | — |
ammo | int | — |
Returns void
Usage
SetPedAmmoByType(ped, ammoType, ammo)
-- always works, by hash
Citizen.InvokeNative(0x5FD1E1F011E76D7E, ped, ammoType, ammo)JavaScript and C#
SetPedAmmoByType(ped, ammoType, ammo);
// by hash
Citizen.invokeNative('0x5FD1E1F011E76D7E', ped, ammoType, ammo);Function.Call((Hash)0x5FD1E1F011E76D7E, ped, ammoType, 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.