The Lab
PED native

_ADD_TEXTURE_LAYER

returns int7 paramsbuild 1207

Adds a layer to the custom ped texture textureId using the given albedo, normal and material hashes, blend type and alpha, and returns the new layer index.

Used when building custom skin or overlay textures for MP-style peds.

Signature

C
int _ADD_TEXTURE_LAYER(int textureId, Hash albedoHash, Hash normalHash, Hash materialHash, int blendType, float texAlpha, int sheetGridIndex); // 0x86BB5FF45F193A02 b1207

Parameters

#NameType
1textureIdint
2albedoHashHash
3normalHashHash
4materialHashHash
5blendTypeint
6texAlphafloat
7sheetGridIndexint

Facts

Facts about _ADD_TEXTURE_LAYER
Name
_ADD_TEXTURE_LAYER
Hash
0x86BB5FF45F193A02
Namespace
Returns
int
Game build
1207

Examples

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

Lua
local result = Citizen.InvokeNative(0x86BB5FF45F193A02, -- _ADD_TEXTURE_LAYER
  0, -- int textureId
  GetHashKey("name"), -- Hash albedoHash
  GetHashKey("name"), -- Hash normalHash
  GetHashKey("name"), -- Hash materialHash
  0, -- int blendType
  0.0, -- float texAlpha
  0, -- int sheetGridIndex
  Citizen.ResultAsInteger()
)
print(result)
JavaScript
// Whole JS numbers are sent as integers: pass floats like 1.5 (or n + 0.0000001), never 1.
const result = Citizen.invokeNative("0x86BB5FF45F193A02", // _ADD_TEXTURE_LAYER
  0, // int textureId
  GetHashKey("name"), // Hash albedoHash
  GetHashKey("name"), // Hash normalHash
  GetHashKey("name"), // Hash materialHash
  0, // int blendType
  0.0, // float texAlpha
  0, // int sheetGridIndex
  Citizen.resultAsInteger()
);
console.log(result)
C#
int result = Function.Call<int>((Hash)0x86BB5FF45F193A02, // _ADD_TEXTURE_LAYER
  0, // int textureId
  (uint)API.GetHashKey("name"), // Hash albedoHash
  (uint)API.GetHashKey("name"), // Hash normalHash
  (uint)API.GetHashKey("name"), // Hash materialHash
  0, // int blendType
  0.0f, // float texAlpha
  0 // int sheetGridIndex
);
All PED natives

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