Why is the actor component invisible after added through "add component by class" in the runtime?

I have an Actor blueprint called BP_city to which I want to add a actor component called BP_market. I first spawn the BP_city actor in another blueprint’s begin play event, then I use the “add component by class” node and specify the class as BP_market to add it to the newly spawned BP_city.


But when I check the result in the runtime with PIE outliner, I find there is no BP_market component under the BP_city actor.

I’m sure that the BP_market component is actually generated under BP_city actor, because the output length of “get component by class” is 1, not 0, which means there is one BP_market component there. Also if I remove the “add component by class” node, the output length is 0.

Also, If I add the BP_market component manually to the BP_city in blueprint editor, then I can see it direclty in the runtime.


Why is there such a difference?Anybody who knows it please help to answer. Thanks!

1 Like

Anybody knows how to make the dynamic added actor component visible please help, thanks :+1: :+1: :+1: