PedClient

isPedOnVehicle

IS_PED_ON_VEHICLE0x67722AEB798E5FAB

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

SignatureJavaScript
isPedOnVehicle(ped: Ped): boolean
SignatureLua
isPedOnVehicle(ped: Ped): boolean

Usage

JavaScript
const result = isPedOnVehicle(ped);
Lua
local result = isPedOnVehicle(ped)

Parameters

ParameterTypeJavaScriptLua
pedPednumberinteger

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.

Gets a value indicating whether the specified ped is on top of any vehicle.

Return 1 when ped is on vehicle.
Return 0 when ped is not on a vehicle.

Reference

Namespace
Ped PED
In the game
BOOL IS_PED_ON_VEHICLE(Ped ped)
Hash
0x67722AEB798E5FAB

Open in the interactive natives reference