Navigation
API > API/Plugins > API/Plugins/WaveFunctionCollapse
Inheritance Hierarchy
- UObjectBase
- UObjectBaseUtility
- UObject
- UDataAsset
- UWaveFunctionCollapseModel
References
| Module | WaveFunctionCollapse |
| Header | /Engine/Plugins/Experimental/WaveFunctionCollapse/Source/WaveFunctionCollapse/Public/WaveFunctionCollapseModel.h |
| Include | #include "WaveFunctionCollapseModel.h" |
Syntax
UCLASS&40;Blueprintable, BlueprintType&41;
class UWaveFunctionCollapseModel : public UDataAsset
Remarks
A Model of WFC constraints. This data asset should contain all necessary data to allow for a WFC solve of an arbitrary grid size.
Variables
| Type | Name | Description | |
|---|---|---|---|
| TMap< FWaveFunctionCollapseOption, FWaveFunctionCollapseAdjacencyToOptionsMap > | Constraints | ||
| TArray< FSoftObjectPath > | SpawnExclusion | ||
| float | TileSize | Grid Tile Size in cm^3 |
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | AddConstraint
(
const FWaveFunctionCollapseOption& KeyOption, |
Create a constraint | |
| int32 | Get the total count of constraints in this model | ||
| int32 | GetOptionContribution
(
const FWaveFunctionCollapseOption& Option |
Get the contribution value of an option | |
| FWaveFunctionCollapseOptions | GetOptions
(
const FWaveFunctionCollapseOption& KeyOption, |
Get all options for a given key option in a given adjacency | |
| float | GetOptionWeight
(
const FWaveFunctionCollapseOption& Option |
Get the weight value of an option | |
| void | SetAllContributions
(
int32 Contribution |
Set the contribution values of key objects to a given value | |
| void | SetAllWeights
(
float Weight |
Set the weights of key objects to a given value | |
| void | SetOptionContribution
(
const FWaveFunctionCollapseOption& Option, |
Set the contribution value of a key object to a given value | |
| void | Set the weights of key objects based on their contribution values | ||
| void | SwapMeshes
(
TMap< UStaticMesh*, UStaticMesh* > SourceToTargetMeshMap |
Swap meshes in the model with other meshes based on a map. |