Parent/Child bug crashes Engine

I have a parent “Tree” and a child “Tree Broadleaf”.

In Tree I have a function which spawns a “Tree Broadleaf” and calls one function on it, a function which is inside of the Tree class:

http://puu.sh/hDJER/fbdfbb287b.png

Initialize is a function of the Tree class.

The red error is “Error COMPILER ERROR: failed building connection with ‘Tree Broadleaf Reference is not compatible with Self Reference.’ at SpawnActor Tree Broadleaf”

And the yellow warning is

http://puu.sh/hDJVn/3b14d4eb59.png

In 4.7.5 the bug also were there but I workarounded it with casting the spawned Tree Broadleaf to Tree and then call Initialize on the Tree, but this produces a warning in 4.8 and crashes the Engine after hitting play.

If I use a reroute node between the return value and the target of the function, I actually don’t get any Error but just Warnings!

http://puu.sh/hVSo1/0c3664bf87.png

I can add, if I try to override “Initialize” in the child (Tree Broadleaf) and connect the parent initialize node and compile, the engine also crashes.

Hello ,

I was unable to reproduce this issue on our end with the information provided. I have a few question for you that will help narrow down what issue it is that you are experiencing.

Quick questions:

  1. Can you reproduce this issue in a clean project?
  2. If so, could you provide a detailed list of steps to reproduce this issue on our end?
  3. Is this a project that has been updated from an older version of the engine?
  4. Could you provide a screen shot of the rest of the blueprints that are involved with this issue (example: the function that is shown)?

The questions are a bit strange, why should anyone use the 4.8 preview with not updating an older project? I don’t think anyone will start a new project with a preview version.
I have not tried to reproduce this in a clean project. Steps would be to Create a Parent blueprint, create a child blueprint, spawn the child in the parent and call a function of the parent on the child.
The function in which the child is spawned is just doing a lot of traces, nothing special.

Yes I have been able to reproduce this in a clean project.

,

With the additional information provided in your last post I was able to reproduce the error that you are seeing on your end. However, I was not able to reproduce the crash that you were talking about. I found that if I had a function (we will call it child’s function) and this function handled the task of spawning the child actor as well as calling the other function that is owned by the parent (we will call it parent’s function) that I was then able to call the child’s function within the parent without any issues. If you could elaborate on exactly what it is you are trying to achieve I may be able to help you find a workaround for the issue that you are facing. Also, if you could provide more information how how exactly you are going from getting the errors to getting the engine to crash that would be most helpful. Could you provide your crash logs?

Getting the crash is done with casting the child to the parent and then call the parent function on the casted actor. Then the error is gone and only one warning is there. Then place the child in the world and hit play.

Ok this does not always work, here an even easier way to get a crash: Go into the child, override the parents function and connect the “parent function” to the exec node. Then hit compile. Engine will crash.

like this:

http://puu.sh/hDXZz/896248fc14.png

If it does not directly crash, remove the overriden function and hit compile.

Hello ,

I was able to reproduce the crash reported in your last post. I have written up a report ( UE-15137) and I have submitted it to the developers for further consideration. I will provide updates with any pertinent information as it becomes available. Thank you for your information and time.

Make it a great day

Thanks! Is UE-15137 both the crash and the Error with the nodes or only the crash?

Hello ,

The report above is for the crash and it has been resolved in the latest internal build. This solution will be available in a future release. As for the error, the report number is UE-15593.

Make it a great day

Thanks! And what’s about the Error and Warnings with the Nodes?

Hello ,

I wasn’t clear the second number (UE-15593) that was mentioned in my last post was for the error and warning that were mentioned above. UE-15137 is for the crash. Both issue have been reported. However, only the crash is currently been resolved. I hope this clears up any questions that you had about the issues.

Make it a great day

Yeah it’s clear now! Thanks a lot!

I have added another screenshot regarding UE-15593 which might help your developers to find the problem…

Hello,

I tested the issue UE-15593 in the 4.11 preview 4 and it appears that this has been resolved.

Make it a great day

Hi Rudy, thanks for letting me know!