RealDocs

UKismetSystemLibrary::GetSoftClassReferenceFromPrimaryAssetId

function Engine Blueprint Since unknown
#include "Kismet/KismetSystemLibrary.h"
Access: public Specifiers: staticUFUNCTIONBlueprintPure

Description

Returns the soft class reference (path) associated with a Primary Asset Id. Works even if the class asset is not loaded.

Caveats & Gotchas

  • Only meaningful for Primary Asset Ids that were registered against a class asset; for regular objects use GetSoftObjectReferenceFromPrimaryAssetId.
  • Returns a null TSoftClassPtr if the asset has not been scanned by the Asset Manager.

Signature

static TSoftClassPtr<UObject> GetSoftClassReferenceFromPrimaryAssetId(FPrimaryAssetId PrimaryAssetId)

Parameters

Name Type Description Default
PrimaryAssetId FPrimaryAssetId The Primary Asset Id to convert.

Return Type

TSoftClassPtr<UObject>

Example

Defer class loading C++
FPrimaryAssetId AssetId(FName("Character"), FName("Hero_Warrior"));
TSoftClassPtr<UObject> SoftClass = UKismetSystemLibrary::GetSoftClassReferenceFromPrimaryAssetId(AssetId);
// Pass SoftClass to an async loader later

Version History

Introduced in: unknown

Version Status Notes
5.6 stable

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.