So when I jump and keep my "horizontal" key pressed, after landing the animation starts gliding.
But only when the skeleton isn't selected in the editor.
When it's not selected it doesn't detect the animation change, if it is, it does notice the change somehow and everything looks good.
I was wondering if someone else has the same issue or this is just a bug?
In the code I do check that if the animation = landing animation, it should trigger either the idle or the walk depending on what is needed. And it does respond to that... when the skeleton is selected.. but not else.
Tried several different ways of checking but I'm wondering why it works when the skeleton is selected and not when it isn't..
example code of one of the checks I tried:
(this is inside an isGrounded check btw and the x represents the horizontal input from both controller-axis and button)
Spine.Animation LandingAnimationNormal = skeletonAnimation.skeleton.Data.FindAnimation("Normal_Jump_Landing");
bool isPlayingLandingNormal = (skeletonAnimation.state.GetCurrent(0).Animation == LandingAnimationNormal);
if (isPlayingLandingNormal && x == 0)
{
skeletonAnimation.AnimationName = idleNormalName;
}
if (isPlayingLandingNormal && x != 0)
{
skeletonAnimation.AnimationName = walkName;
}