_GET_CLOSEST_FIRE_POS_IN_VOLUME
Hash
0x559FC1D310813031Runtime name
GetClosestFirePosInVolumeNamespaceFIRE
SideClient
NameCommunity guess
Docs
Since build1232
Signature
BOOL _GET_CLOSEST_FIRE_POS_IN_VOLUME(Vector3* outPosition, float posX, float posY, float posZ, float rotX, float rotY, float rotZ, float scaleX, float scaleY, float scaleZ);Parameters
| Name | Type | Description |
|---|---|---|
outPosition | Vector3* | — |
posX | float | — |
posY | float | — |
posZ | float | — |
rotX | float | — |
rotY | float | — |
rotZ | float | — |
scaleX | float | — |
scaleY | float | — |
scaleZ | float | — |
Returns BOOL
Usage
local retval, outPosition = GetClosestFirePosInVolume(posX, posY, posZ, rotX, rotY, rotZ, scaleX, scaleY, scaleZ)
-- always works, by hash
local retval, outPosition = Citizen.InvokeNative(0x559FC1D310813031, Citizen.PointerValueVector(), posX, posY, posZ, rotX, rotY, rotZ, scaleX, scaleY, scaleZ, Citizen.ReturnResultAnyway())JavaScript and C#
const [retval, outPosition] = GetClosestFirePosInVolume(posX, posY, posZ, rotX, rotY, rotZ, scaleX, scaleY, scaleZ);
// by hash
const [retval, outPosition] = Citizen.invokeNative('0x559FC1D310813031', Citizen.pointerValueVector(), posX + 0.0000001, posY + 0.0000001, posZ + 0.0000001, rotX + 0.0000001, rotY + 0.0000001, rotZ + 0.0000001, scaleX + 0.0000001, scaleY + 0.0000001, scaleZ + 0.0000001, Citizen.returnResultAnyway());var outPosition = new OutputArgument();
bool retval = Function.Call<bool>((Hash)0x559FC1D310813031, outPosition, posX, posY, posZ, rotX, rotY, rotZ, scaleX, scaleY, scaleZ);
// outPosition.GetResult<Vector3>()- Float parameters: Lua integers (
10, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write10.0orvalue + 0.0. The generated JS wrappers add0.0000001to non-zero floats for the same reason. - Pointer (out) arguments are not passed in Lua/JS: their values are returned after the result, in order.
- The name is a community guess and may change. If the named call is missing in your client build, use
InvokeNativewith the hash — it always works.
Sources
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.