RedM Natives

GET_PED_SCRIPT_TASK_STAGE

Gets the stage of the peds scripted task.

Hash0x44B0E5E2
Runtime nameGetPedScriptTaskStage
NamespaceCFX
SideServer
NameOfficial
Docs

Signature

int GET_PED_SCRIPT_TASK_STAGE(Ped ped);

Parameters

NameTypeDescription
pedPed

The target ped.

Returns int — The stage of the ped's scripted task. A value of 3 denotes no script task is assigned.

Description

Cfx.re native reference

Gets the stage of the peds scripted task.

Usage

Lua
local retval = GetPedScriptTaskStage(ped)

-- always works, by hash
local retval = Citizen.InvokeNative(0x44b0e5e2, ped, Citizen.ResultAsInteger())
JavaScript and C#
JavaScript
const retval = GetPedScriptTaskStage(ped);

// by hash
const retval = Citizen.invokeNative('0x44b0e5e2', ped, Citizen.returnResultAnyway(), Citizen.resultAsInteger());
C#
int retval = Function.Call<int>((Hash)0x44b0e5e2, ped);

Sources

Cfx.re native reference

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