doesWeaponTakeWeaponComponent
DOES_WEAPON_TAKE_WEAPON_COMPONENT0x5CEE3DF569CECAB0The GTA V native DOES_WEAPON_TAKE_WEAPON_COMPONENT of the WEAPON namespace, as LS:MP client scripts call it: the global function doesWeaponTakeWeaponComponent, in JavaScript and in Lua.
doesWeaponTakeWeaponComponent(weaponHash: Hash, componentHash: Hash): booleandoesWeaponTakeWeaponComponent(weaponHash: Hash, componentHash: Hash): booleanUsage
JavaScript
const result = doesWeaponTakeWeaponComponent(weaponHash, componentHash);Lua
local result = doesWeaponTakeWeaponComponent(weaponHash, componentHash)Parameters
| Parameter | Type | JavaScript | Lua |
|---|---|---|---|
weaponHash | Hash | number | integer |
componentHash | Hash | number | integer |
Returns
BOOL JavaScript boolean, Lua booleanNotes
From the community native database. Names are LS:MP’s; samples may be written for C++ or another framework.
Full list of weapons & components by DurtyFree: https://github.com/DurtyFree/gta-v-data-dumps/blob/master/weapons.json
Reference
- Namespace
- Weapon WEAPON
- In the game
BOOL DOES_WEAPON_TAKE_WEAPON_COMPONENT(Hash weaponHash, Hash componentHash)- Hash
0x5CEE3DF569CECAB0