REGISTER_HATED_TARGETS_AROUND_PED
Based on TASK_COMBAT_HATED_TARGETS_AROUND_PED, the parameters are likely similar (PedHandle, and area to attack in).
Hash
0x9222F300BF8354FERuntime name
RegisterHatedTargetsAroundPedNamespacePED
SideClient
NameOfficial
Docs
Since build1207
GTA V hash
0x9222F300BF8354FESignature
void REGISTER_HATED_TARGETS_AROUND_PED(Ped ped, float radius);Parameters
| Name | Type | Description |
|---|---|---|
ped | Ped | — |
radius | float | — |
Returns void
Description
Based on TASK_COMBAT_HATED_TARGETS_AROUND_PED, the parameters are likely similar (PedHandle, and area to attack in).
Usage
RegisterHatedTargetsAroundPed(ped, radius)
-- always works, by hash
Citizen.InvokeNative(0x9222F300BF8354FE, ped, radius)JavaScript and C#
RegisterHatedTargetsAroundPed(ped, radius);
// by hash
Citizen.invokeNative('0x9222F300BF8354FE', ped, radius + 0.0000001);Function.Call((Hash)0x9222F300BF8354FE, ped, radius);- Float parameters: Lua integers (
10, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write10.0orvalue + 0.0. The generated JS wrappers add0.0000001to non-zero floats for the same reason.
Sources
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.