countPedsInCombatWithTargetWithinRadius
COUNT_PEDS_IN_COMBAT_WITH_TARGET_WITHIN_RADIUS0x336B3D200AB007CBThe GTA V native COUNT_PEDS_IN_COMBAT_WITH_TARGET_WITHIN_RADIUS of the PED namespace, as LS:MP client scripts call it: the global function countPedsInCombatWithTargetWithinRadius, in JavaScript and in Lua.
countPedsInCombatWithTargetWithinRadius(
ped: Ped,
x: number,
y: number,
z: number,
radius: number
): numbercountPedsInCombatWithTargetWithinRadius(
ped: Ped,
x: number,
y: number,
z: number,
radius: number
): integerUsage
JavaScript
const result = countPedsInCombatWithTargetWithinRadius(ped, x, y, z, radius);Lua
local result = countPedsInCombatWithTargetWithinRadius(ped, x, y, z, radius)Three consecutive numbers can be given as one vector: { x, y, z } (or [x, y, z]) in JavaScript, a Vector3 in Lua.
JavaScript · with vectors
const result = countPedsInCombatWithTargetWithinRadius(ped, pos, radius);Lua · with vectors
local result = countPedsInCombatWithTargetWithinRadius(ped, pos, radius)Parameters
| Parameter | Type | JavaScript | Lua |
|---|---|---|---|
ped | Ped | number | integer |
x | float | number | number |
y | float | number | number |
z | float | number | number |
radius | float | number | number |
Returns
int JavaScript number, Lua integerReference
- Namespace
- Ped PED
- In the game
int COUNT_PEDS_IN_COMBAT_WITH_TARGET_WITHIN_RADIUS(Ped ped, float x, float y, float z, float radius)- Hash
0x336B3D200AB007CB