GetTerrainHeightFlatness
Appearance
| Environment: | Mission Scripting | |
|---|---|---|
| Function: | GetTerrainHeightFlatness | |
| Function Description: | Returns a height difference value | |
| File Location: | cmm.positionFunctions.lua | |
| Syntax: | CMM.GetTerrainHeightFlatness( table vec3 , number or nil radius , number or nil limit ) | |
| Return Value: | number or boolean or nil | |
| Parameters: | Name | Description |
| vec3 | Vec3 table with x, y, z coordinates | |
| radius | A number representing the radius in meters around the point to sample terrain heights [DEFAULT: 30] | |
| limit | An optional number representing a maximum acceptable height difference; if provided, the function will return a boolean indicating whether the height difference is within this limit. | |
| Example: | CMM.GetTerrainHeightFlatness({x=100, y=50, z=10}) | |
| Example Description: | Returns the closest point on the road network to the given position, or the original position if no roads are found. | |
| Related Functions: | ||
| Notes: | ||