Native referenceFiveM

GET_GROUND_Z_EXCLUDING_OBJECTS_FOR_3D_COORD

0x9E82F0F362881B29 MISC
FUNCTION SIGNATURE
BOOL GET_GROUND_Z_EXCLUDING_OBJECTS_FOR_3D_COORD(float x, float y, float z, float* groundZ, BOOL waterAsGround);
Property Value
Native Name GET_GROUND_Z_EXCLUDING_OBJECTS_FOR_3D_COORD
Hash 0x9E82F0F362881B29
Return Type BOOL
Parameters x (float), y (float), z (float), groundZ (float*), waterAsGround (BOOL)

Description: Determines the highest ground Z-coordinate directly below a specified 3D coordinate, excluding any objects at that point. Optionally, water can be considered as ground when determining the highest point.

NativeDB Added Parameter 6: BOOL ignoreDistToWaterLevelCheck - If set to true, the distance to the water level will be ignored when checking for water as ground. 
NativeDB Introduced: v505

Parameters

  • x (float) — X-coordinate of the point to check.
  • y (float) — Y-coordinate of the point to check.
  • z (float) — Z-coordinate of the point to check.
  • groundZ (float*) — A pointer to a float where the ground Z-coordinate will be stored if found.
  • waterAsGround (BOOL) — If set to true, water will be included in the check, and its height will be returned if it is higher than the ground level.
Back to MISC