starfckr

  • Jun 9, 2023
  • Joined Jan 31, 2023
  • @starfckr The code is looking good in general, however this constructor call is allocating for too many keyframes (event keys):

    Spine.EventTimeline newTimeline = new EventTimeline(asset.Animation.Timelines.Items[0].FrameCount);

    You should be good with new EventTimeline(events.Count); from the number of ClipEvents in your events collection.

    In general we recommend looking at the respective source code section, like SkeletonJson.cs : L1088 in this case. Then you can also use a debugger to step through the code and observe the already working skeleton loading scenario.