Skip to content

shapetest


start_shape_test_los_probe

int native.shapetest.start_shape_test_los_probe(float x1, float y1, float z1, float x2, float y2, float z2, int flags, int entity, int p8)

Asynchronously starts a line-of-sight (raycast) world probe shape test.

Use the handle with 0x3D87450E15D98694 or 0x65287525D951F6BE until it returns 0 or 2.

p8 is a bit mask with bits 1, 2 and/or 4, relating to collider types; 4 should usually be used.

_0x04aa59ca40571c2e

int native.shapetest._0x04aa59ca40571c2e(int p0, int p1)


start_expensive_synchronous_shape_test_los_probe

int native.shapetest.start_expensive_synchronous_shape_test_los_probe(float x1, float y1, float z1, float x2, float y2, float z2, int flags, int entity_to_ignore, int p8)

Does the same as 0x7EE9F5D83DD4F90E, except blocking until the shape test completes.

start_shape_test_box

int native.shapetest.start_shape_test_box(float pos_x, float pos_y, float pos_z, float dimensions_x, float dimensions_y, float dimensions_z, float rot_x, float rot_y, float rot_z, int rotation_order, int flags, int entity_to_ignore, int options)


start_shape_test_capsule

int native.shapetest.start_shape_test_capsule(float x1, float y1, float z1, float x2, float y2, float z2, float radius, int flags, int entity_to_ignore, int p9)


start_shape_test_swept_sphere

int native.shapetest.start_shape_test_swept_sphere(float x1, float y1, float z1, float x2, float y2, float z2, float radius, int flags, int entity, int p9)


start_shape_test_mouse_cursor_los_probe

int native.shapetest.start_shape_test_mouse_cursor_los_probe(ref vec3 p_vec1, ref vec3 p_vec2, int flag, int entity, int flag2)

Old name: _START_SHAPE_TEST_SURROUNDING_COORDS

get_shape_test_result

int native.shapetest.get_shape_test_result(int shape_test_handle, ptr int hit, ref vec3 end_coords, ref vec3 surface_normal, ptr int entity_hit)

Returns the result of a shape test: 0 if the handle is invalid, 1 if the shape test is still pending, or 2 if the shape test has completed, and the handle should be invalidated.

When used with an asynchronous shape test, this native should be looped until returning 0 or 2, after which the handle is invalidated.

enum eShapeTestStatus
{
    SHAPETEST_STATUS_NONEXISTENT,
    SHAPETEST_STATUS_RESULTS_NOTREADY,
    SHAPETEST_STATUS_RESULTS_READY
};