SET_PED_DROPS_INVENTORY_WEAPON
Makes the ped drop the weapon weaponHash from its inventory at the given offset with ammoCount rounds.
Signature
void SET_PED_DROPS_INVENTORY_WEAPON(Ped ped, Hash weaponHash, float xOffset, float yOffset, float zOffset, int ammoCount); // 0x208A1888007FC0E6 b1207Parameters
| # | Name | Type |
|---|---|---|
| 1 | ped | Ped |
| 2 | weaponHash | Hash |
| 3 | xOffset | float |
| 4 | yOffset | float |
| 5 | zOffset | float |
| 6 | ammoCount | int |
Facts
| Name | SET_PED_DROPS_INVENTORY_WEAPON |
|---|---|
| Hash | 0x208A1888007FC0E6 |
| Namespace | |
| Returns | void |
| Game build | 1207 |
Examples
Calls by hash work in every RedM runtime. Replace the placeholder arguments with your own values.
Citizen.InvokeNative(0x208A1888007FC0E6, -- SET_PED_DROPS_INVENTORY_WEAPON
PlayerPedId(), -- Ped ped
GetHashKey("weapon_revolver_cattleman"), -- Hash weaponHash
0.0, -- float xOffset
0.0, -- float yOffset
0.0, -- float zOffset
0 -- int ammoCount
)// Whole JS numbers are sent as integers: pass floats like 1.5 (or n + 0.0000001), never 1.
Citizen.invokeNative("0x208A1888007FC0E6", // SET_PED_DROPS_INVENTORY_WEAPON
PlayerPedId(), // Ped ped
GetHashKey("weapon_revolver_cattleman"), // Hash weaponHash
0.0, // float xOffset
0.0, // float yOffset
0.0, // float zOffset
0 // int ammoCount
);Function.Call((Hash)0x208A1888007FC0E6, // SET_PED_DROPS_INVENTORY_WEAPON
API.PlayerPedId(), // Ped ped
(uint)API.GetHashKey("weapon_revolver_cattleman"), // Hash weaponHash
0.0f, // float xOffset
0.0f, // float yOffset
0.0f, // float zOffset
0 // int ammoCount
);Related WEAPON natives
- SET_PED_DROPS_WEAPONS_WHEN_DEAD
- _SET_AMMO_TYPE_FOR_PED_WEAPON_INVENTORY
- SET_PED_CURRENT_WEAPON_VISIBLE
- SET_PLAYER_PED_QUICK_SWAP_WEAPON_BY_GUID
- SET_CURRENT_PED_VEHICLE_WEAPON
- SET_CURRENT_PED_WEAPON
- SET_CURRENT_PED_WEAPON_BY_GUID
- _GET_BEST_PED_WEAPON_IN_INVENTORY
- _GET_WEAPON_FROM_DEFAULT_PED_WEAPON_COLLECTION
- _SET_AMMO_TYPE_FOR_PED_WEAPON
- _SET_PED_WEAPON_ATTACH_POINT_VISIBILITY
- SET_PED_AMMO
Facts compiled from community research (alloc8or/rdr3-nativedb-data, femga/rdr3_discoveries); descriptions and examples by The Lab.