[Question] Multiple DefaultSceneRoot components?

G’day,

I keep getting an odd error message:

Warning AttachTo: '/Engine/Transient.World_<#>:PersistentLevel..DefaultSceneRoot' cannot be attached to itself. Aborting.

The Blueprints affected all have one thing in common - multiple ‘inherited’ DefaultSceneRoot components.

Assuming a bad SceneComponent::AttachTo(), I disabled the function that uses it.

No luck.

Even creating a ‘fresh’ blueprint didn’t fix the problem.

Any suggestions on what I’m doing to cause this, if anything?

Thank you.

Kris

A little update.

I created a new base blueprint for clothing that attaches to the torso. As soon as I reparented or creating new blueprints based on it, the error appeared for these too.

Inventory (C++) → Clothing (C++) → BaseClothing (Blueprint) → = No Error.

Inventory (C++) → Clothing (C++) → BaseClothing (Blueprint) → BaseTorso (Blueprint) → = Error.

Hmm…

Kris

hi there,

this issue has been resolved internally and should be fixed in the next release.

as a potential workaround until then, if your Blueprints are based on a native C++ AActor subclass that you’ve defined, you can create and then explicitly set a “native” root component in your C++ constructor for the native C++ subclass upon which the Blueprint hierarchy is based. this can be a simple USceneComponent subobject named “DefaultSceneRoot” (or any name you wish) that you could create in the C++ constructor like so:

MyNativeRootComponent = CreateDefaultSubobject(this, "DefaultSceneRoot");
SetRootComponent(MyNativeRootComponent);

if you’re basing your Blueprint hierarchy on the native AActor class directly (or any other “stock” AActor subclass that doesn’t itself contain any USceneComponent subobjects), you’ll first need to subclass it in order to do that.

again the workaround above should be unnecessary with the next release.

hope this helps! -phil.

Cheers Philip.

I’ll give the work around a shot.

Thanks.

Kris