RedM Natives

_SET_CHAR_EXPRESSION

Sets MetaPedExpression at index specified.

Hash0x5653AB26C82938CF
Runtime nameSetCharExpression
NamespacePED
SideClient
NameCommunity guess
Docs
Since build1207

Signature

void _SET_CHAR_EXPRESSION(Ped ped, int index, float value);

Parameters

NameTypeDescription
pedPed—
indexint—
valuefloat—

Returns void

Description

alloc8or RDR3 NativeDB

Sets MetaPedExpression at index specified. Morphs components, such as changing body size or facial features.

Note: You have to update the ped's variation (using 0xCC8CA3E88256E58F) after calling this native

index = MetaPedExpression IDs
List of face features: https://pastebin.com/9jb88FXW
Full list of MetaPedExpressions: https://pastebin.com/Ld76cAn7
value: -1.0 to 1.0 (values beyond this likely won't sync to other clients)

This native also allows you to change a horse's gender.

Old name: _SET_PED_FACE_FEATURE

femga rdr3_discoveries · research notes

// 0x5653AB26C82938CF     By Disquse , Pichotm, Sicario
void _SET_PED_FACE_FEATURE(Ped ped, int index, float value);
/*
  Note: you have to reset ped's customization after calling, for example use "0xCC8CA3E88256E58F"
  Safe values are from -1.0 to 1.0.
  This native is also allowing you to change horse's gender.
*/

Known indexes:
https://pastebin.com/9jb88FXW

Usage example:
  const ped = PlayerPedId();
  const faceFeatures = [ /* indexes */ ];

  for (const index of faceFeatures) {
    // Here comes your value
    const value = (Math.random() * 4) - 2;

    // Calling _SET_PED_FACE_FEATURE
    Citizen.invokeNative("0x5653AB26C82938CF", ped, index, value);
  }

  // Reseting ped's customization.
  Citizen.invokeNative("0xCC8CA3E88256E58F", ped, false, true, true, true, false);

https://gfycat.com/redfinedartfrog

Usage

Lua
SetCharExpression(ped, index, value)

-- always works, by hash
Citizen.InvokeNative(0x5653AB26C82938CF, ped, index, value)
JavaScript and C#
JavaScript
SetCharExpression(ped, index, value);

// by hash
Citizen.invokeNative('0x5653AB26C82938CF', ped, index, value + 0.0000001);
C#
Function.Call((Hash)0x5653AB26C82938CF, ped, index, value);
  • Float parameters: Lua integers (10, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write 10.0 or value + 0.0. The generated JS wrappers add 0.0000001 to non-zero floats for the same reason.
  • 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.

See also

Sources

alloc8or RDR3 NativeDB · femga rdr3_discoveries

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