Log In
Sign Up
Game code

WEAPON::GET_CURRENT_PED_WEAPON

0x465FE2ABC5781BB4 ·RVA 0x04A82950

Signature

BOOL GET_CURRENT_PED_WEAPON(
    Ped ped,
    Hash* weaponHash,
    int p2,
    BOOL p4
);

The scripts pass 5 values to this native; the decoded signature lists 4 (arguments the game doesn't read are left out).

Parameters 4

#TypeNameNotes
0Pedped –
1Hash*weaponHash –
2intp2 –
3BOOLp4 –

Returns

BOOL

Notes

  • Names from RDR3; types from the game code, which differs from RDR3's signature:
  • attachPoint, in RDR3's signature, is not passed in GTA VI.
  • This lines up with RDR3's signature in more than one way; it takes the one that keeps RDR3's arguments first and puts the new ones after them.

Call it

// WEAPON::GET_CURRENT_PED_WEAPON
auto result = invoke<BOOL>(0x465FE2ABC5781BB4, ped, &weaponHash, p2, p4);

Generic call-by-hash templates in the style of the common GTA V / RDR2 script frameworks. Adapt the types to your tooling.

Improve this page

Know what this native does, a better name, or the real parameter types? Suggest an edit. A moderator reviews every suggestion, and approved edits credit you here.