RedM Natives

_GET_PED_COMPONENT_CATEGORY_BY_INDEX

Returns category hash that each ped component has.

Hash0xCCB97B51893C662F
Runtime nameGetPedComponentCategoryByIndex
NamespacePED
SideClient
NameCommunity guess
Docs
Since build1207

Signature

Hash _GET_PED_COMPONENT_CATEGORY_BY_INDEX(Ped ped, int index);

Parameters

NameTypeDescription
pedPed—
indexint—

Returns Hash

Description

Returns category hash that each ped component has. Hash examples: MASKS, HATS, HEADS, HORSE_MANES

Usage

Lua
local retval = GetPedComponentCategoryByIndex(ped, index)

-- always works, by hash
local retval = Citizen.InvokeNative(0xCCB97B51893C662F, ped, index, Citizen.ResultAsInteger())
JavaScript and C#
JavaScript
const retval = GetPedComponentCategoryByIndex(ped, index);

// by hash
const retval = Citizen.invokeNative('0xCCB97B51893C662F', ped, index, Citizen.returnResultAnyway(), Citizen.resultAsInteger());
C#
int retval = Function.Call<int>((Hash)0xCCB97B51893C662F, ped, index);
  • The name is a community guess and may change. If the named call is missing in your client build, use InvokeNative with the hash — it always works.

Sources

alloc8or RDR3 NativeDB

Something wrong or missing? Contribute a verified note — corrections ship through pull requests.