VisibleAnywhere macro doesn't work in nested components

I have created a custom actor component, named UMyActorComponent and I’ve added the following public property:

UPROPERTY(VisibleAnywhere)
 USpringArmComponent* Arm1;

then, inside the constructor of the component I create the spring arm component using the following code:

Arm1 = CreateDefaultSubobject<USpringArmComponent>(FName("Arm1"));

After that, I declared UMyActorComponent in my character’s class using the following property:

UPROPERTY(VisibleAnywhere)
 UMyActorComponent* ActorComp;

and inside the constructor of my character I initialized the component using the following code:

ActorComp = CreateDefaultSubobject<UMyActorComponent>(FName("ActorComp"));

However, when I compile my code and go to the Blueprint Editor I’m unable to edit the Arm1 using the details panel:

I’ve tried to use a SceneComponent instead of an ActorComponent however the same bug occurs.

If I declare the Arm1 as EditAnywhere, I am able to edit it by selecting the ActorComp inside my character and then adjusting its properties, however the following issues arise:

  • You are unable to see the changes you perform in the Arm1 so for example, if you change it’s socket offset you have to deselect the ActorComp and select the Arm1 to determine if the value you’ve entered matches your needs.
  • In case you change the socket offset and compile the character’s Blueprint, the socket offset will get reseted, however in the details panel it still holds the old value.

Is there a standard workflow to create nested components and edit them using the details panel that I’m missing, or is this an actual bug?

Hey Orfeas-

I also encountered the empty details panel when tested and the process of making a change in the ActorComp then selecting Arm1 to confirm would be a workflow problem. I have entered the bug report UE-32795 to investigate this behavior.

Cheers

god two years later and this bug is still here, now I have to use the blueprint construction script to edit the defaults :c

Edit: that actually doesn’t even work, also the engine crashes whenever I attempt to spawn the actor which’s components disappeared