PedClient

isPedInCover

IS_PED_IN_COVER0x60DFD0691A170B88

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

SignatureJavaScript
isPedInCover(ped: Ped, exceptUseWeapon: boolean): boolean
SignatureLua
isPedInCover(ped: Ped, exceptUseWeapon: boolean): boolean

Usage

JavaScript
const result = isPedInCover(ped, exceptUseWeapon);
Lua
local result = isPedInCover(ped, exceptUseWeapon)

Parameters

ParameterTypeJavaScriptLua
pedPednumberinteger
exceptUseWeaponBOOLbooleanboolean

Returns

BOOL JavaScript boolean, Lua boolean

Notes

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

p1 is nearly always 0 in the scripts.

Reference

Namespace
Ped PED
In the game
BOOL IS_PED_IN_COVER(Ped ped, BOOL exceptUseWeapon)
Hash
0x60DFD0691A170B88

Open in the interactive natives reference