RealDocs

AActor::IsAsset

function Engine Since 4.0
#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);
}

Version History

Introduced in: 4.0

Version Status Notes
5.6 stable

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.