ClearAreaOfProjectiles
DocsClearAreaOfProjectiles(x, y, z, radius, createNetEvent)Description
Clears an area of projectiles at the given coordinates and radius.
Parameters
| Name | Type | Description |
|---|---|---|
x | float | The x coordinate of where to clear projectiles. |
y | float | The y coordinate of where to clear projectiles. |
z | float | The z coordinate of where to clear projectiles. |
radius | float | The area radius to clear projectiles. |
createNetEvent | BOOL | specifies whether a `CClearAreaEvent` event of should be created for online use. |
Quick Snippet: Get Coordinatesxyz
xyzAdd this command to your client script to retrieve precise locations in-game.
-- Add this to your client.lua. Type /pos in-game to copy coords.
RegisterCommand('pos', function()
local ped = PlayerPedId()
local coords = GetEntityCoords(ped)
local heading = GetEntityHeading(ped)
local output = string.format("vector4(%.2f, %.2f, %.2f, %.2f)", coords.x, coords.y, coords.z, heading)
print(output)
TriggerEvent('chat:addMessage', { args = { '^4[COORD]^0', output } })
end)Returns
voidThis native does not return a value.
Examples
Official
-- Clear the area, do also create an event
ClearAreaOfProjectiles(0.0, 0.0, 0.0, 10000.0, true)