How to detach child from parent on "death" in Blueprint character

I was asking for clarification about what you intend for this relationship to mean, as in, does the child follow the parents transformation?

That is typically what it would mean but you were vague so I wanted to clarify.

I understand what you mean now though, and I agree with above: don’t bother with the child actor thing because it will add more complications than necessary.

In the blueprint of the thing that can die and follows some other actor, just use a Attach Actor to Actor (there are some other attach nodes as well) node and get a reference to the one that you wish to be the parent.

Here is example from my project:

When the death event fires, you can add this:

image

In my case, I used Attach Actor to Component, that way I can use a scene component to define a specific place to attach the actor.

Another important benefit to keeping the actors separated this way is that you’ll be able to refactor this all so that the two classes never need to know about each other. In blueprint you can accomplish that sort of decoupling using interfaces. I don’t believe you would be able to accomplish that using the Child Actor feature.

3 Likes