Hello, how do i reference all children from a parent?

So in my AI, to target hostiles i have the enemies get all actors of class and select my parent. However, the enemies will not attack the children, only the parent. Shouldnt they also attack the children? I tried “get all child actors” as well and that did not work.
heckel_redo.bmp (1.2 MB)

I would like to have one single parent actor that is “all enemy types in the game” and have that be the only class i need to do a loop for when selecting targets. How would i go about doing this?

tl;dr: a Child Actor nothing to do with inheritance. It’s just an actor spawned by a Child Actor Component. Which I assume is not the case here at all.


For a Base Enemy class + 3 child classes :

Get All would fetch any and all instances of the parent and / or children.

Thanks for the reply, can u show the proper way to make those child’s of the parent class? Because im not quite following here. This seems like exactly what i already did?

old.bmp (236.2 KB)
I used this

Normally, you’d right click the class in the Content Browser and:

But re-parenting also works (most of the time).


But the issue in your script is with this node:

It does not do what you think it does. It works with this component:

Not with class inheritance.

1 Like

OH thank you! very helpful!