IS_PED_A_PLAYER
This native checks if the given ped is a player.
Signature
BOOL IS_PED_A_PLAYER(Ped ped);Parameters
| Name | Type | Description |
|---|---|---|
ped | Ped | — |
Returns BOOL — Returns `true` if the ped is a player, `false` otherwise.
Description
This native checks if the given ped is a player.
Usage
local retval = IsPedAPlayer(ped)
-- always works, by hash
local retval = Citizen.InvokeNative(0x404794ca, ped, Citizen.ReturnResultAnyway())JavaScript and C#
const retval = IsPedAPlayer(ped);
// by hash
const retval = Citizen.invokeNative('0x404794ca', ped, Citizen.returnResultAnyway());bool retval = Function.Call<bool>((Hash)0x404794ca, ped);Sources
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.