How to get Object Reference to Actor spawned from array?

Hey, guys, need help.

I spawn a specific actor using Actor Class Reference, then get the Return Value and work with this Object Reference


Everything works.

But I need to spawn several of such Actors.
So I use an array of them.

And nothing works, the link breaks.

I can probably understand why it is done this way… But how can I fix this thing? How can I work with those spawned actors?

1 Like

Since you’ve connected the Class pin on the spawn node, it can only return parent class now. Make Unit Actor type - so it can accept any actor. Or make Unit the base class of the mechs - so it can accept any mech.

1 Like

You have deleted your previous message, but it actually helped me. I moved this function into a parent object and now I am simply calling it after I spawn each actor from the actor itself.

1 Like

Because I misread the script and misunderstood the task at hand.