AActor::IsAsset
#include "GameFramework/Actor.h"
Access: public
Specifiers: virtualoverride
Description
Returns whether this actor should be treated as a standalone asset (e.g. Blueprint class actors that are the root object of their package). Used by the Asset Registry and content browser to classify objects.
Caveats & Gotchas
- • Most in-level actors are not assets; this returns true primarily for Blueprint actors that act as the outermost object of a `.uasset` package.
- • Do not confuse with IsMainPackageActor — IsAsset is about whether the object represents a content-browser asset, while IsMainPackageActor checks whether it is the primary actor in a package.
Signature
ENGINE_API virtual bool IsAsset() const override; Return Type
bool Example
Check before treating an actor as an asset C++
if (MyActor->IsAsset())
{
// Safe to pass to Asset Registry APIs
FAssetData AssetData(MyActor);
} See Also
Tags
Version History
Introduced in: 4.0
| Version | Status | Notes |
|---|---|---|
| 5.6 | stable | — |
Feedback
Was this helpful?