getApproxFloorForArea

GET_APPROX_FLOOR_FOR_AREA0x3599D741C9AC6310

The GTA V native GET_APPROX_FLOOR_FOR_AREA of the PATHFIND namespace, as LS:MP client scripts call it: the global function getApproxFloorForArea, in JavaScript and in Lua.

SignatureJavaScript
getApproxFloorForArea(x1: number, y1: number, x2: number, y2: number): number
SignatureLua
getApproxFloorForArea(x1: number, y1: number, x2: number, y2: number): number

Usage

JavaScript
const value = getApproxFloorForArea(x1, y1, x2, y2);
Lua
local value = getApproxFloorForArea(x1, y1, x2, y2)

Parameters

ParameterTypeJavaScriptLua
x1floatnumbernumber
y1floatnumbernumber
x2floatnumbernumber
y2floatnumbernumber

Returns

float JavaScript number, Lua number

Reference

Namespace
Pathfinding PATHFIND
In the game
float GET_APPROX_FLOOR_FOR_AREA(float x1, float y1, float x2, float y2)
Hash
0x3599D741C9AC6310
Formerly
_GET_HEIGHTMAP_BOTTOM_Z_FOR_AREA

Open in the interactive natives reference