_SET_CHAR_EXPRESSION
Sets MetaPedExpression at index specified.
0x5653AB26C82938CFSetCharExpressionSignature
void _SET_CHAR_EXPRESSION(Ped ped, int index, float value);Parameters
| Name | Type | Description |
|---|---|---|
ped | Ped | — |
index | int | — |
value | float | — |
Returns void
Description
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/redfinedartfrogUsage
SetCharExpression(ped, index, value)
-- always works, by hash
Citizen.InvokeNative(0x5653AB26C82938CF, ped, index, value)JavaScript and C#
SetCharExpression(ped, index, value);
// by hash
Citizen.invokeNative('0x5653AB26C82938CF', ped, index, value + 0.0000001);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. Write10.0orvalue + 0.0. The generated JS wrappers add0.0000001to 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
InvokeNativewith the hash — it always works.
See also
_GET_CHAR_EXPRESSIONGets MetaPedExpression at index specified For index, see: _SET_CHAR_EXPRESSION Old name: _GET_PED_FACE_FEATURE
Sources
alloc8or RDR3 NativeDB · femga rdr3_discoveries
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.