• RuntimesUnreal
  • UE5: keeps crashing. Please help

bbt636 Could you please tell us what operations you are performing before the crash occurs? Perhaps from your description, the installation of the spine-ue runtime and the import of the skeleton data is going well, but the crash occurs while you are doing something with the skeleton. Am I right? To what extent can operations be successfully performed, e.g. can a skeleton be successfully instantiated in a level?

Related Discussions
...

In fact I have no major problem, the characters animations run well, every character appears fine, is like a time thing, after some time in the game it just crashes and shows that error as the cause.

    The crash report says :
    UnrealEditor_SpinePlugin!UTrackEntry::BeginDestroy() [G:\Archive\PersonalProjects\RankerAcademy\Rankers\Rankers\Plugins\SpinePlugin\Source\SpinePlugin\Private\SpineSkeletonAnimationComponent.cpp:87]

    bbt636 I understand your situation. Unfortunately, the steps to reproduce the issue are currently unclear, making it difficult to investigate further without a reproduction project. Could you prepare a minimal Unreal Engine project where the problem can be reliably reproduced and email it to us?: contact@esotericsoftware.com
    Please include the URL of this forum thread in the email so we know the context. Then we can take a look at what's wrong.

    rankers.log
    280kB

    This is the log, I have to add that I am not a programmer so any help is greatly appreciated.

    I went through the log, and while it does mention the incorrectly initializede FSpineEvent structs, it doesn't give me a stack trace for the crash which would allow me to understand what is happening.

    Is there any way you could share your project either here or privately via email (contact@esotericsoftware.com) with steps to reproduce the issue?

    Mail sent

      bbt636 Thank you for sending the video and project files! We were able to reproduce the crash and will investigate the cause of the problem. As soon as we find out anything, we will let you know in this thread.

      15 أيام لاحقا

      hI, were you able to find the problem?

      • Luke replied to this.
        • تم التحرير

        bbt636 We're still investigating why UE keeps crashing in regards to your project. I apologize for the delay; we'll respond here as soon as we can.

        This is extremely hard to figure out I'm afraid. I've been banging my head against it for a few days, without much progress. UE's garbage collector is ... peculiar.

        I've pushed a supposed fix, please give it a try.

        The issue: spine-ue exposes TrackEntry instances. These are wrapped inside a USpineTrackEntry, so users of blueprints can easily access and modify them, e.g. set mix durations etc. These are UObjects and thus eligible for UE garbage collection. Normally, the garbage collection happens after the underlying TrackEntry is disposed. Disposal of a TrackEntry triggers a callback in the USpineWidget or USpineSkeletonAnimatinComponent, which will then set the USpineTrackEntry::entry field to nullptr. However, sometimes, under specific circumstances, that callback has no chance to be executed before the USpineTrackEntry::BeginDestroy() method, which is triggered by the UE garbage collector, is invoked. This can lead to a situation, where the USpineTrackEntry::entry points to a freed memory region, while USpineTrackEntry::BeginDestroy() is trying to access the ::entry field. That results in a crash.

        The solution: do not access ::entry in the BeginDestroy() method. While this sounds trivial, I had to trace through everything to make sure this doesn't mess with other state, which is part of why resolving this took so long.

          Mario Thanks a lot I will try it