PedClient1 output

isPedEvasiveDiving

IS_PED_EVASIVE_DIVING0x414641C26E105898

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

SignatureJavaScript
isPedEvasiveDiving(ped: Ped): [ok: boolean, evadingEntity: Entity]
SignatureLua
isPedEvasiveDiving(ped: Ped): boolean, Entity

Usage

JavaScript
const [ok, evadingEntity] = isPedEvasiveDiving(ped);
Lua
local ok, evadingEntity = isPedEvasiveDiving(ped)

Parameters

ParameterTypeJavaScriptLua
pedPednumberinteger

Returns

2 values, in this order: an array in JavaScript, multiple return values in Lua.

#ValueTypeJavaScriptLuaDescription
1okBOOLbooleanbooleanThe native’s own return value.
2evadingEntityEntitynumberintegeroutput

Notes

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

Presumably returns the Entity that the Ped is currently diving out of the way of.

var num3;
    if (isPedEvasiveDiving(A_0, &num3) != 0)
        if (isEntityAVehicle(num3) != 0)

Reference

Namespace
Ped PED
In the game
BOOL IS_PED_EVASIVE_DIVING(Ped ped, Entity* evadingEntity)
Hash
0x414641C26E105898

Open in the interactive natives reference