Skip to content
Orbdale

Orbdale Terrain · OrbdaleTerrain module · member function

UOrbdaleTerrainLibrary::

SampleGroundBatch

Blueprint

Many positions on one snapshot, results in input order.

Declaration

UFUNCTION(BlueprintCallable, Category="Orbdale|Terrain|Query", meta=(AutoCreateRefTerm="Locations", WorldContext="WorldContextObject"))
static TArray<FOrbdaleTerrainGroundSample> SampleGroundBatch(const UObject* WorldContextObject, const TArray<FVector>& Locations,
                                                              UPARAM(meta=(Bitmask, BitmaskEnum="/Script/OrbdaleTerrain.EOrbdaleTerrainSampleFields")) int32 Fields,
                                                              EOrbdaleTerrainAccuracy Accuracy = EOrbdaleTerrainAccuracy::Best,
                                                              EOrbdaleTerrainSurface Surface = EOrbdaleTerrainSurface::Modified);
Blueprint Sample Ground Batch
The graph as text
  1. Sample Ground Batch (function call)
    • In Locations (array of Vector): not connected
    • In Fields (Integer): 0
    • In Accuracy (EOrbdaleTerrainAccuracy): Best
    • In Surface (EOrbdaleTerrainSurface): Modified
    • Out Return Value (array of OrbdaleTerrainGroundSample): not connected
Header
#include "OrbdaleTerrainLibrary.h"
Module
PublicDependencyModuleNames.Add("OrbdaleTerrain"); in your module’s Build.cs.
Stability
Stable: changes within a major version only add.
Thread
Game thread (Blueprint). (the rule of UOrbdaleTerrainLibrary)
Blueprint
Sample Ground Batch, in Orbdale › Terrain › Query

Parameters

NameTypeDefaultMeaning
WorldContextObjectconst UObject*—

Any object in the world whose terrain is read; supplies the world.

Locationsconst TArray<FVector>&—

World cm. Up to 65,536 per call; the rest are answered NoData, with a warning in the log.

Fieldsint32—

A bit mask of EOrbdaleTerrainSampleFields; the height is always computed.

AccuracyEOrbdaleTerrainAccuracyEOrbdaleTerrainAccuracy::Best

Best, ExactOnly or Coarse (EOrbdaleTerrainAccuracy).

SurfaceEOrbdaleTerrainSurfaceEOrbdaleTerrainSurface::Modified

Which ground to read (EOrbdaleTerrainSurface); Modified is the current ground.

Note.

Use this over a loop of SampleGround: one snapshot, one pass.