Tooling
This commit is contained in:
@@ -40,4 +40,15 @@ public:
|
||||
static ALandscape* CreateLandscapeFromHeightmap(UWorld* World, const FString& HeightmapFile,
|
||||
const TArray<FLandscapeAuthoringWeightmap>& Weightmaps, UMaterialInterface* Material,
|
||||
FVector Location, FVector Scale, int32 WorldPartitionGridSize = 4);
|
||||
|
||||
// Creates a ULandscapeLayerInfoObject asset carrying LayerName, which is the name the landscape material
|
||||
// blends by and the name a weightmap is imported against.
|
||||
//
|
||||
// The second thing the engine exposes no Python path to, and for the same reason as the first. There is no
|
||||
// LayerInfo factory in the bindings, and ULandscapeLayerInfoObject::LayerName is VisibleAnywhere - so the
|
||||
// obvious workaround, duplicating an existing layer info, produces an asset that silently keeps the name it
|
||||
// was copied from and paints that substance wherever the new layer should be. Returns null and logs why on
|
||||
// failure; an existing asset at the path is returned rather than replaced, so this is safe to rerun.
|
||||
UFUNCTION(BlueprintCallable, Category = "Salty|Authoring")
|
||||
static ULandscapeLayerInfoObject* CreateLayerInfo(const FString& PackagePath, const FString& AssetName, FName LayerName);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user