The Lab
WEAPON native

GET_PED_WEAPON_GUID_AT_ATTACH_POINT

returns BOOL3 paramsbuild 1207

Writes the GUID of the weapon at the given attach point of the ped to weaponGuid. Returns true on success.

Signature

C
BOOL GET_PED_WEAPON_GUID_AT_ATTACH_POINT(Ped ped, int attachPoint, Any* weaponGuid); // 0x6929E22158E52265 b1207

Parameters

#NameType
1pedPed
2attachPointint
3weaponGuidAny* (out pointer)

Facts

Facts about GET_PED_WEAPON_GUID_AT_ATTACH_POINT
Name
GET_PED_WEAPON_GUID_AT_ATTACH_POINT
Hash
0x6929E22158E52265
Namespace
Returns
BOOL
Game build
1207

Examples

Calls by hash work in every RedM runtime. Replace the placeholder arguments with your own values.

Lua
local result, weaponGuid = Citizen.InvokeNative(0x6929E22158E52265, -- GET_PED_WEAPON_GUID_AT_ATTACH_POINT
  PlayerPedId(), -- Ped ped
  0, -- int attachPoint
  Citizen.PointerValueInt(), -- Any* weaponGuid
  Citizen.ReturnResultAnyway()
)
if result then
  -- ...
end
JavaScript
const [result, weaponGuid] = Citizen.invokeNative("0x6929E22158E52265", // GET_PED_WEAPON_GUID_AT_ATTACH_POINT
  PlayerPedId(), // Ped ped
  0, // int attachPoint
  Citizen.pointerValueInt(), // Any* weaponGuid
  Citizen.returnResultAnyway()
);
if (result) {
  // ...
}
C#
var weaponGuidArg = new OutputArgument();
bool result = Function.Call<bool>((Hash)0x6929E22158E52265, // GET_PED_WEAPON_GUID_AT_ATTACH_POINT
  API.PlayerPedId(), // Ped ped
  0, // int attachPoint
  weaponGuidArg // Any* weaponGuid
);
int weaponGuid = weaponGuidArg.GetResult<int>();
All WEAPON natives

Facts compiled from community research (alloc8or/rdr3-nativedb-data, femga/rdr3_discoveries); descriptions and examples by The Lab.