PedClient

setPedAlternateMovementAnim

SET_PED_ALTERNATE_MOVEMENT_ANIM0x90A43CC281FFAB46

The GTA V native SET_PED_ALTERNATE_MOVEMENT_ANIM of the PED namespace, as LS:MP client scripts call it: the global function setPedAlternateMovementAnim, in JavaScript and in Lua.

SignatureJavaScript
setPedAlternateMovementAnim(
  ped: Ped,
  stance: number,
  animDictionary: string,
  animationName: string,
  p4: number,
  p5: boolean
): void
SignatureLua
setPedAlternateMovementAnim(
  ped: Ped,
  stance: integer,
  animDictionary: string,
  animationName: string,
  p4: number,
  p5: boolean
)

Usage

JavaScript
setPedAlternateMovementAnim(ped, stance, animDictionary, animationName, p4, p5);
Lua
setPedAlternateMovementAnim(ped, stance, animDictionary, animationName, p4, p5)

Parameters

ParameterTypeJavaScriptLua
pedPednumberinteger
stanceintnumberinteger
animDictionarystringstringstring
animationNamestringstringstring
p4floatnumbernumber
p5BOOLbooleanboolean

Returns

Nothing. In JavaScript the call evaluates to undefined.

Notes

From the community native database. Names are LS:MP’s; samples may be written for C++ or another framework.

stance:
0 = idle
1 = walk
2 = running

p5 = usually set to true

Full list of animation dictionaries and anims by DurtyFree: https://github.com/DurtyFree/gta-v-data-dumps/blob/master/animDictsCompact.json

Full list of movement clipsets by DurtyFree: https://github.com/DurtyFree/gta-v-data-dumps/blob/master/movementClipsetsCompact.json

Reference

Namespace
Ped PED
In the game
void SET_PED_ALTERNATE_MOVEMENT_ANIM(Ped ped, int stance, const char* animDictionary, const char* animationName, float p4, BOOL p5)
Hash
0x90A43CC281FFAB46

Open in the interactive natives reference