TASK_COMBAT_HATED_TARGETS_AROUND_PED
Despite its name, it only attacks ONE hated target.
Hash
0x7BF835BB9E2698C8Runtime name
TaskCombatHatedTargetsAroundPedNamespaceTASK
SideClient
NameOfficial
Docs
Since build1207
GTA V hash
0x7BF835BB9E2698C8Signature
void TASK_COMBAT_HATED_TARGETS_AROUND_PED(Ped ped, float radius, int flags, Any p3);Parameters
| Name | Type | Description |
|---|---|---|
ped | Ped | — |
radius | float | — |
flags | int | — |
p3 | Any | — |
Returns void
Description
Despite its name, it only attacks ONE hated target. The one closest hated target.
Usage
TaskCombatHatedTargetsAroundPed(ped, radius, flags, p3)
-- always works, by hash
Citizen.InvokeNative(0x7BF835BB9E2698C8, ped, radius, flags, p3)JavaScript and C#
TaskCombatHatedTargetsAroundPed(ped, radius, flags, p3);
// by hash
Citizen.invokeNative('0x7BF835BB9E2698C8', ped, radius + 0.0000001, flags, p3);Function.Call((Hash)0x7BF835BB9E2698C8, ped, radius, flags, p3);- 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.