taskGotoEntityAiming
TASK_GOTO_ENTITY_AIMING0xA9DA48FAB8A76C12The GTA V native TASK_GOTO_ENTITY_AIMING of the TASK namespace, as LS:MP client scripts call it: the global function taskGotoEntityAiming, in JavaScript and in Lua.
taskGotoEntityAiming(
ped: Ped,
target: Entity,
distanceToStopAt: number,
StartAimingDist: number
): voidtaskGotoEntityAiming(
ped: Ped,
target: Entity,
distanceToStopAt: number,
StartAimingDist: number
)Usage
JavaScript
taskGotoEntityAiming(ped, target, distanceToStopAt, StartAimingDist);Lua
taskGotoEntityAiming(ped, target, distanceToStopAt, StartAimingDist)Parameters
| Parameter | Type | JavaScript | Lua |
|---|---|---|---|
ped | Ped | number | integer |
target | Entity | number | integer |
distanceToStopAt | float | number | number |
StartAimingDist | float | number | number |
Returns
Nothing. In JavaScript the call evaluates to undefined.
Notes
From the community native database. Names are LS:MP’s; samples may be written for C++ or another framework.
eg
taskGotoEntityAiming(v_2, playerPedId(), 5.0, 25.0);ped = Ped you want to perform this task.
target = the Entity they should aim at.
distanceToStopAt = distance from the target, where the ped should stop to aim.
StartAimingDist = distance where the ped should start to aim.
Reference
- Namespace
- Tasks TASK
- In the game
void TASK_GOTO_ENTITY_AIMING(Ped ped, Entity target, float distanceToStopAt, float StartAimingDist)- Hash
0xA9DA48FAB8A76C12