RealDocs

AActor::GetExternalDataLayerAsset

function Engine Since 5.2
#include "GameFramework/Actor.h"
Access: public Specifiers: const

Description

Returns the External Data Layer asset associated with this actor's Content Bundle, if any. External Data Layers allow Content Bundle actors to participate in the host world's data layer streaming.

Caveats & Gotchas

  • Returns nullptr for actors that are not part of a Content Bundle, or whose bundle has no External Data Layer configured. Always null-check before dereferencing.
  • External Data Layers are a niche World Partition feature primarily used for DLC/plugin injection. In most projects this will always return nullptr.

Signature

ENGINE_API const UExternalDataLayerAsset* GetExternalDataLayerAsset() const;

Return Type

const UExternalDataLayerAsset*

Example

Retrieve the external data layer asset for diagnostics C++
if (const UExternalDataLayerAsset* ExtLayer = MyActor->GetExternalDataLayerAsset())
{
    UE_LOG(LogGame, Log, TEXT("Actor belongs to external data layer: %s"),
        *ExtLayer->GetName());
}

Version History

Introduced in: 5.2

Version Status Notes
5.6 stable
5.2 stable Introduced with External Data Layer support for Content Bundles.

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.