turra

Hi, I noticed when switching my animations they were not mixing but instantly changing. I'm setting skeleton_animation_mix("anim1", "anim2", 0.5) so it should be a balanced changeover.

I made 2 new animations which were just the character scaled to plus or minus 1 for a second to see if I could catch it getting stretched inbetween but it seems to instantly flip sides:


I'm not sure if I've done something bad with my animations or if the gamemaker runtime is having an issue or anything else!
For now I might just try and make my own manual mix animations for transitions but it would be nice to sort this out too.
turra
記事: 4

Pharan

Hello!

In the latest runtimes, Spine's scale mixing is implemented such that the destination scale sign is applied immediately, instead of having it scale from -1 to 1 naively. This is because people use negative scale to flip bones between animations but never intend them to flip like paper mario does.

If that was the effect you were going for, it is actually just a matter of removing a block of code in the ScaleTimeline type that favors the destination animation's scale signs.

But Yoyo Games actually manages and maintains their own version of the Spine runtime that's out of our control. And from what I understand, it's precompiled and not user accessible. So there's actually no way to resolve this that way in GameMaker specifically.

So yeah. The way to do it is probably to make those actual custom transition animations rather than relying on Spine's automatic mixing. Or code the scale transition manually instead of relying on Spine animation mixing to do it for you.
アバター
Pharan

Pharan
記事: 4893

turra

Oh that is interesting to know about the scaling! That was actually just an example I made to hopefully show the lack of transition but learn something new every day :)

I managed to get mixing working, I redid the animations making sure to only key the pose at the start of the timeline and that seems to have worked. I think I saw somewhere it needed keys at the end but maybe that actually causes it to have to instantly swap?
Anyways it's all good now, thanks for the help!
turra
記事: 4


Return to Runtimes