taskShootAtCoord
TASK_SHOOT_AT_COORD0x46A6CC01E0826106The GTA V native TASK_SHOOT_AT_COORD of the TASK namespace, as LS:MP client scripts call it: the global function taskShootAtCoord, in JavaScript and in Lua.
taskShootAtCoord(
ped: Ped,
x: number,
y: number,
z: number,
duration: number,
firingPattern: Hash
): voidtaskShootAtCoord(
ped: Ped,
x: number,
y: number,
z: number,
duration: integer,
firingPattern: Hash
)Usage
JavaScript
taskShootAtCoord(ped, x, y, z, duration, firingPattern);Lua
taskShootAtCoord(ped, x, y, z, duration, firingPattern)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
taskShootAtCoord(ped, pos, duration, firingPattern);Lua · with vectors
taskShootAtCoord(ped, pos, duration, firingPattern)Parameters
| Parameter | Type | JavaScript | Lua |
|---|---|---|---|
ped | Ped | number | integer |
x | float | number | number |
y | float | number | number |
z | float | number | number |
duration | int | number | integer |
firingPattern | Hash | number | integer |
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.
Firing Pattern Hash Information: https://pastebin.com/Px036isB
Reference
- Namespace
- Tasks TASK
- In the game
void TASK_SHOOT_AT_COORD(Ped ped, float x, float y, float z, int duration, Hash firingPattern)- Hash
0x46A6CC01E0826106