RedM Natives

_SHOOT_TRIGGER_AT_COORDS

Triggers a gunshot

Hash0x4C57F27D1554E6B0
Runtime nameShootTriggerAtCoords
NamespacePED
SideClient
NameCommunity guess
Docs
Since build1207

Signature

Any _SHOOT_TRIGGER_AT_COORDS(Ped ped, float x, float y, float z, int p4, float p5, int p6, float p7);

Parameters

NameTypeDescription
pedPed—
xfloat—
yfloat—
zfloat—
p4int—
p5float—
p6int—
p7float—

Returns Any

Description

Triggers a gunshot
Params: p5 = -1 in R* Scripts

Usage

Lua
local retval = ShootTriggerAtCoords(ped, x, y, z, p4, p5, p6, p7)

-- always works, by hash
local retval = Citizen.InvokeNative(0x4C57F27D1554E6B0, ped, x, y, z, p4, p5, p6, p7, Citizen.ResultAsInteger())
JavaScript and C#
JavaScript
const retval = ShootTriggerAtCoords(ped, x, y, z, p4, p5, p6, p7);

// by hash
const retval = Citizen.invokeNative('0x4C57F27D1554E6B0', ped, x + 0.0000001, y + 0.0000001, z + 0.0000001, p4, p5 + 0.0000001, p6, p7 + 0.0000001, Citizen.returnResultAnyway(), Citizen.resultAsInteger());
C#
int retval = Function.Call<int>((Hash)0x4C57F27D1554E6B0, ped, x, y, z, p4, p5, p6, p7);
  • Float parameters: Lua integers (10, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write 10.0 or value + 0.0. The generated JS wrappers add 0.0000001 to non-zero floats for the same reason.
  • The name is a community guess and may change. If the named call is missing in your client build, use InvokeNative with the hash — it always works.

Sources

alloc8or RDR3 NativeDB

Something wrong or missing? Contribute a verified note — corrections ship through pull requests.