Is there a way to list Blueprint components?

Hi,

I’m working on a blueprint that consist dozens of rather simple particle systems.Those are separate because I want to have full access to their rotation, location and ability to be hidden at the right moment to get the the best outcome.

These components have many common functions in the blueprint and to avoid a lot of unnecessary work I was wondering if there was a way to get a list or create a list that would include all those dozens of components? I would like to use that list in a loop that would spare me of having to add the same nodes for each and every of of the particle systems over and over again.

Any ideas appreciated!

Just to make sure we are on the same page, I mean these components that you can find at the left corner.

Create an array variable of type Particle System Reference

Then either add the particle files to the array or use the Add node to add all those particles to it on EventBeginPlay or some similar event.

This array willnow allow you to manipulate all of them individually (index 0 = particle1 so Get(1) node would work on ‘particle1’) or you can use a for/foreach/while loop to do things to all of them.

Edit: sorry your variable type should be particle sytem component reference

With that many particle system components you might want to create a function that takes in a particle system component and adds it to your array so that you dont have to connect 2 wires for each one, only 1.

http://i.imgur.com/tBkJLgA.png

http://i.imgur.com/tBkJLgAh.png

If the components/child objects can change dynamically, you can also the Get Children Components or Get Components By Class nodes to get an array of all matching objects.

57028-getcomponentsnodes.png

1 Like

I mixed this with a custom for-each-loop so I that I managed to get the delay in the loop and everything works fine. Thank you for the help!