RedM Index logoRedM Index
NativesHashesClothesBlipsPropsItem Tool
Sign inGet started

Reference

  • Natives
  • Hashes
  • Clothes
  • Blips
  • Props

Namespace

  1. Reference
  2. Natives
  3. GET_SHAPE_TEST_RESULT_INCLUDING_MATERIAL

GET_SHAPE_TEST_RESULT_INCLUDING_MATERIAL

Returns the result of a shape test, also returning the material of any touched surface. When used with an asynchronous shape test, this native should be looped until returning 0 or 2, after which the handle is invalidated. Unless the return value is 2, the other return values are undefined.

CFX

Signature

lua
GetShapeTestResultIncludingMaterial(0, hit, endCoords, surfaceNormal, GetHashKey("..."), entityHit)
-- returns int

Parameters

NameTypeDescription
intA shape test handle.
BOOL*Whether or not the shape test hit any collisions.
Vector3*The resulting coordinates where the shape test hit a collision.
Vector3*The surface normal of the hit position.
Hash*hash of the hit material or surface type, see materialFX.dat
Entity*Any dynamic entity hit by the shape test.

Usage

lua
GetShapeTestResultIncludingMaterial(0, hit, endCoords, surfaceNormal, GetHashKey("..."), entityHit)

Generated from the native name, hash, and parameter list. Add a real example.

Details

Hash
API set
Source
cfx

Source: cfx

On this page

  • Signature
  • Parameters
  • Usage
  • Details