Skip to content

FSMAssetImportManager

Module: SMAssetTools

Public Functions

Name
DECLARE_MULTICAST_DELEGATE_OneParam(FOnAssetImportedSignature , const USMAssetImporter::FImportResult & )
virtual ~FSMAssetImportManager()
void RegisterImporter(const FString & InImporterName, UClass * InImporterClass)
void UnregisterImporter(const FString & InImporterName)
USMAssetImporter::FImportResult ImportAsset(const USMAssetImporter::FImportArgs & InImportArgs)
TArray< FString > GetSupportedImportTypes() const
FOnAssetImportedSignature & OnAssetImported()

Public Functions Documentation

function DECLARE_MULTICAST_DELEGATE_OneParam

DECLARE_MULTICAST_DELEGATE_OneParam(
    FOnAssetImportedSignature ,
    const USMAssetImporter::FImportResult & 
)

function ~FSMAssetImportManager

inline virtual ~FSMAssetImportManager()

function RegisterImporter

void RegisterImporter(
    const FString & InImporterName,
    UClass * InImporterClass
)

Registers an importer to use with state machine assets.

Parameters:

InImporterName
The name to register the importer under, such as "json".
InImporterClass
The class to instantiate when the importer is used.

function UnregisterImporter

void UnregisterImporter(
    const FString & InImporterName
)

Unregisters an importer for use with state machine assets.

Parameters:

InImporterName
The name of the previously registered importer.

function ImportAsset

USMAssetImporter::FImportResult ImportAsset(
    const USMAssetImporter::FImportArgs & InImportArgs
)

Import a state machine to a blueprint.

Parameters:

InImportArgs
Arguments to use when importing an asset.

Return: The blueprint created or used to receive the import data.


function GetSupportedImportTypes

TArray< FString > GetSupportedImportTypes() const

Return a list of all supported import types.


function OnAssetImported

inline FOnAssetImportedSignature & OnAssetImported()

Called when an asset has been imported.


Private Attributes Documentation

variable MappedImporters

TMap< FString, TSubclassOf< USMAssetImporter > > MappedImporters;

variable OnAssetImportedEvent

FOnAssetImportedSignature OnAssetImportedEvent;