Adding a Blueprint Component at Runtime by passing in Component Class

So i noticed in Blueprint, each Component has its own separate node for adding that Component to a Blueprint, but what about being able to pass a Component class into a node and it adding that Component to a Blueprint?

Is this feature planned, or is the current method the only one that will be supported?

(Incase you dont understand what i mean, look at Spawn Actor, and see how it allows you to pass in the Class of the Actor you want to spawn.)<-- I want this but for adding Components to Blueprints during runtime.

Thanks, all help is much appreciated.

It would be nice to have this functionality, bump. In that case the component type to be added can be editable, which is very convenient.

Hello,

I have gone ahead and entered a feature request, UE-22653. Thank you for your feedback.

Have a great day,

Sean Flint

any update on this?

Hey Taisaku,

Here’s a link to the bug on our public tracker so you can keep an eye on its status: Unreal Engine Issues and Bug Tracker (UE-22653)

Have a great day

Is this still not done? This seems to be some essential functionality. I have a related question to this. Is there no way to have something like NewObject in Blueprint? Why does the Construct Object From Class node not work with components (I just get “Wrong class to spawn” which is not very helpfull)?

Feature requests typically take a lower priority due to the developer’s focus on high-priority crash and showstopper bugs. However, you do have access to source, so if you’d like to implement the feature you are welcome to enter a pull request.

As far as NewObject goes, as far as I’m aware, this isn’t exposed to blueprints.

Construct Object From Class is limited to classes that inherit directly from Object. This forum thread may be relevant depending on your use case: Construct Object From Class - "Wrong class to spawn" error - Initializing objects via blueprint - Blueprint Visual Scripting - Unreal Engine Forums

Have a great day

+1 It would be lovely to have this for things like skill systems. I’m trying to create a component from class but getting a “Cannot construct objects of type…”

222335-ue4editor-2017-12-03-03-33-38.png

Hmm, I was just looking at how to do this and am a little sad to find this thread since it seems to be saying that I can’t?