TasksClient

taskLookAtCoord

TASK_LOOK_AT_COORD0x6FA46612594F7973

The GTA V native TASK_LOOK_AT_COORD of the TASK namespace, as LS:MP client scripts call it: the global function taskLookAtCoord, in JavaScript and in Lua.

SignatureJavaScript
taskLookAtCoord(
  entity: Entity,
  x: number,
  y: number,
  z: number,
  duration: number,
  flags: number,
  priority: number
): void
SignatureLua
taskLookAtCoord(
  entity: Entity,
  x: number,
  y: number,
  z: number,
  duration: integer,
  flags: integer,
  priority: integer
)

Usage

JavaScript
taskLookAtCoord(entity, x, y, z, duration, flags, priority);
Lua
taskLookAtCoord(entity, x, y, z, duration, flags, priority)

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
taskLookAtCoord(entity, pos, duration, flags, priority);
Lua · with vectors
taskLookAtCoord(entity, pos, duration, flags, priority)

Parameters

ParameterTypeJavaScriptLua
entityEntitynumberinteger
xfloatnumbernumber
yfloatnumbernumber
zfloatnumbernumber
durationintnumberinteger
flagsintnumberinteger
priorityintnumberinteger

Returns

Nothing. In JavaScript the call evaluates to undefined.

Reference

Namespace
Tasks TASK
In the game
void TASK_LOOK_AT_COORD(Entity entity, float x, float y, float z, int duration, int flags, int priority)
Hash
0x6FA46612594F7973

Open in the interactive natives reference