UKismetSystemLibrary::GetClassTopLevelAssetPath
#include "Kismet/KismetSystemLibrary.h"
Access: public
Specifiers: staticUFUNCTIONBlueprintPure
Description
Returns the full path to the specified class as an FTopLevelAssetPath, the lightweight identifier used by the asset registry and asset utilities.
Caveats & Gotchas
- • Blueprint DisplayName is "Get Class Path Name (Top Level Asset Path)" — search by that string if you can't find the node by C++ name.
- • FTopLevelAssetPath only stores package name + asset name, not a full soft path, so it can't be loaded directly the way FSoftClassPath can.
- • Returns an invalid path if Class is null.
Signature
static FTopLevelAssetPath GetClassTopLevelAssetPath(const UClass* Class) Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| Class | const UClass* | The class to get the path name of. | — |
Return Type
FTopLevelAssetPath Example
Compare classes by path for asset registry lookups C++
FTopLevelAssetPath PawnPath = UKismetSystemLibrary::GetClassTopLevelAssetPath(AMyPawn::StaticClass());
if (PawnPath == FTopLevelAssetPath(TEXT("/Game/Blueprints"), TEXT("BP_MyPawn_C")))
{
// matched
} See Also
Tags
Version History
Introduced in: 5.1
| Version | Status | Notes |
|---|---|---|
| 5.6 | stable | — |
Feedback
Was this helpful?