IAssetTools::CreateAsset

Creates an asset with the specified name, path, and factory

Windows
MacOS
Linux

References

Module

AssetTools

Header

/Engine/Source/Developer/AssetTools/Public/IAssetTools.h

Include

#include "IAssetTools.h"

Syntax

UObject * CreateAsset
(
    const FString & AssetName,
    const FString & PackagePath,
    UClass * AssetClass,
    UFactory * Factory,
    FName CallingContext
)

Remarks

Creates an asset with the specified name, path, and factory

Returns

the new asset or NULL if it fails

Parameters

Parameter

Description

AssetName

the name of the new asset

PackagePath

the package that will contain the new asset

AssetClass

the class of the new asset

Factory

the factory that will build the new asset

CallingContext

optional name of the module or method calling CreateAsset() - this is passed to the factory

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss