START_SHAPE_TEST_CAPSULE
Starts an asynchronous capsule test between two points with the given radius, ignoring entityToIgnore, and returns a handle for GET_SHAPE_TEST_RESULT.
Signature
ScrHandle START_SHAPE_TEST_CAPSULE(float x1, float y1, float z1, float x2, float y2, float z2, float radius, int flags, Entity entityToIgnore, int p9); // 0x28579D1B8F8AAC80 b1207Parameters
| # | Name | Type |
|---|---|---|
| 1 | x1 | float |
| 2 | y1 | float |
| 3 | z1 | float |
| 4 | x2 | float |
| 5 | y2 | float |
| 6 | z2 | float |
| 7 | radius | float |
| 8 | flags | int |
| 9 | entityToIgnore | Entity |
| 10 | p9 | int |
Facts
| Name | START_SHAPE_TEST_CAPSULE |
|---|---|
| Hash | 0x28579D1B8F8AAC80 |
| Namespace | |
| Returns | ScrHandle |
| Game build | 1207 |
Examples
Calls by hash work in every RedM runtime. Replace the placeholder arguments with your own values.
local scrHandle = Citizen.InvokeNative(0x28579D1B8F8AAC80, -- START_SHAPE_TEST_CAPSULE
0.0, -- float x1
0.0, -- float y1
0.0, -- float z1
0.0, -- float x2
0.0, -- float y2
0.0, -- float z2
0.0, -- float radius
0, -- int flags
PlayerPedId(), -- Entity entityToIgnore
0, -- int p9
Citizen.ResultAsInteger()
)
print(scrHandle)// Whole JS numbers are sent as integers: pass floats like 1.5 (or n + 0.0000001), never 1.
const scrHandle = Citizen.invokeNative("0x28579D1B8F8AAC80", // START_SHAPE_TEST_CAPSULE
0.0, // float x1
0.0, // float y1
0.0, // float z1
0.0, // float x2
0.0, // float y2
0.0, // float z2
0.0, // float radius
0, // int flags
PlayerPedId(), // Entity entityToIgnore
0, // int p9
Citizen.resultAsInteger()
);
console.log(scrHandle)int scrHandle = Function.Call<int>((Hash)0x28579D1B8F8AAC80, // START_SHAPE_TEST_CAPSULE
0.0f, // float x1
0.0f, // float y1
0.0f, // float z1
0.0f, // float x2
0.0f, // float y2
0.0f, // float z2
0.0f, // float radius
0, // int flags
API.PlayerPedId(), // Entity entityToIgnore
0 // int p9
);Related SHAPETEST natives
Facts compiled from community research (alloc8or/rdr3-nativedb-data, femga/rdr3_discoveries); descriptions and examples by The Lab.