RedM Index logoRedM Index
NativesHashesClothesBlipsPropsItem Tool
Sign inGet started

Reference

  • Natives
  • Hashes
  • Clothes
  • Blips
  • Props

Namespace

  1. Reference
  2. Natives
  3. _GET_WEAPON_FROM_DEFAULT_PED_WEAPON_COLLECTION

_GET_WEAPON_FROM_DEFAULT_PED_WEAPON_COLLECTION

this native gets the weapon hash from the default ped weapon collection (see GetDefaultPedWeaponCollection for more info) will randomly return one of it's weapons

WEAPONBuild 1207

Signature

lua
GetWeaponFromDefaultPedWeaponCollection(GetHashKey("..."), GetHashKey("..."))
-- returns Hash

Parameters

NameTypeDescription
Hash—
Hash—

Usage

Named call
GetWeaponFromDefaultPedWeaponCollection(GetHashKey("..."), GetHashKey("..."))
InvokeNative
Citizen.InvokeNative(0x9EEFD670F10656D7, GetHashKey("..."), GetHashKey("..."))
lua 1
local pedWeaponCollectionHash = GetDefaultPedWeaponCollection(joaat("mp_u_m_m_interrogator_01"))
local hash = Citizen.InvokeNative(0x9EEFD670F10656D7, pedWeaponCollectionHash, joaat("GROUP_REVOLVER"))
if hash and IsWeaponValid(hash) then
local name = GetWeaponName(hash)
local label = GetLabelText_2(name)
print(name, label)
end

Details

Hash
Source
VORPCORE/RDR3natives

Source: VORPCORE/RDR3natives

On this page

  • Signature
  • Parameters
  • Usage
  • Details