Orrery Terrain · OrreryTerrain module · class
UOrreryTerrainSourceAsset
Where a terrain's natural ground comes from, as an asset (Tier 3).
Declaration
UCLASS(Abstract, BlueprintType)
class UOrreryTerrainSourceAsset : public UDataAsset- Header
#include "OrreryTerrainSourceAsset.h"- Module
PublicDependencyModuleNames.Add("OrreryTerrain");in your module’s Build.cs.- Stability
- Stable: changes within a major version only add.
- Thread
- Game thread.
- Derives from
UDataAsset- Blueprint
- “Orrery Terrain Source Asset”, a Blueprint type
Description
Holds the grid and the source's parameters as reflected data, and bakes them down into a Tier-1 OrreryTerrain::Native::ITileSource when a terrain is created. Nothing keeps a pointer back to the asset after that: the source is a plain C++ object owned by the terrain world, so the asset can be collected or hot-reloaded without touching a live terrain (the "bake assets, then let go" pattern of the GC Boundary note).
The grid lives here, not on the actor: the origin is double precision (LWC) and is part of the natural ground's identity, so a save made over this source only loads over it.
Game thread. Abstract: use a subclass.
Functions
- MakeTileSource
Bake the asset into a Tier-1 source.
- MakeGrid
The grid in Tier-1 form.
- MakeConfig
The terrain configuration this source implies (grid, resident mips, default batter, undo-ring bounds).
- ValidateGridprotected
Whether the grid can carry a terrain: a finite origin, a positive base cell, an edit subdivision of 1, 2 or 4.
- ValidateExtentprotected
Whether an inclusive tile range is non-empty.
- MetresToMmCheckedprotected
A height or length in metres as whole millimetres within int32, rounded half away from zero.
Properties
| Name | Type | Default | Meaning |
|---|---|---|---|
Origin_BlueprintReadOnly | FVector2 | FVector2 | World position of base post (0,0) of tile (0,0), metres. |
BaseBlueprintReadOnly | double | 1.0 | Natural-ground post spacing, metres. An imported Landscape's X and Y scale of 100 is 1 m. |
EditBlueprintReadOnly | uint8 | 1 | Edit cell = BaseCell_m / EditSubdivision. 1, 2 or 4. |
ResidentBlueprintReadOnly | uint8 | 5 | Mip levels at or above this stay resident (5 = 32 m posts at a 1 m base). |
On | FOn | — | Fired by PostEditChangeProperty (editor only) after any property of any source asset changed. A live editor-world terrain made from the asset subscribes to re-create itself, so editing the asset needs no scan of the world's actors and no editor module in the runtime module. |