TasksClientChecked by LS:MP

taskScriptedAnimation

TASK_SCRIPTED_ANIMATION0x126EF75F1E17ABE5

The GTA V native TASK_SCRIPTED_ANIMATION of the TASK namespace, as LS:MP client scripts call it: the global function taskScriptedAnimation, in JavaScript and in Lua.

SignatureJavaScript
taskScriptedAnimation(
  ped: Ped,
  priorityLowData: ScriptedAnimSlot,
  priorityMidData: ScriptedAnimSlot,
  priorityHighData: ScriptedAnimSlot,
  blendInDelta: number,
  blendOutDelta: number
): void
SignatureLua
taskScriptedAnimation(
  ped: Ped,
  priorityLowData: table,
  priorityMidData: table,
  priorityHighData: table,
  blendInDelta: number,
  blendOutDelta: number
)

Usage

JavaScript
taskScriptedAnimation(
  ped, priorityLowData, priorityMidData, priorityHighData, blendInDelta, blendOutDelta
);
Lua
taskScriptedAnimation(
    ped, priorityLowData, priorityMidData, priorityHighData, blendInDelta, blendOutDelta
)

Parameters

ParameterTypeJavaScriptLua
pedPednumberinteger
priorityLowDataScriptedAnimSlotScriptedAnimSlottable
priorityMidDataScriptedAnimSlotScriptedAnimSlottable
priorityHighDataScriptedAnimSlotScriptedAnimSlottable
blendInDeltafloatnumbernumber
blendOutDeltafloatnumbernumber

Returns

Nothing. In JavaScript the call evaluates to undefined.

On LS:MP

ℹ
Local ped animation

Use a local ped owned by the calling resource. Supply up to three priority records and load each animation dictionary before calling. Both blend deltas must be between 0 and 1,000.

ℹ
GTA V Enhanced 1158.16

This LS:MP adapter is available on Enhanced 1158.16. Calls on another build raise an error.

Reference

Namespace
Tasks TASK
In the game
void TASK_SCRIPTED_ANIMATION(Ped ped, ScriptedAnimSlot priorityLowData, ScriptedAnimSlot priorityMidData, ScriptedAnimSlot priorityHighData, float blendInDelta, float blendOutDelta)
Hash
0x126EF75F1E17ABE5

Open in the interactive natives reference