Search Unity

Unity 5.2 Mecanim Transitions not working the same as 5.1

Discussion in 'Animation' started by David-Flook, Sep 9, 2015.

  1. David-Flook

    David-Flook

    Joined:
    Nov 13, 2013
    Posts:
    47
    Since I've upgraded from 5.1 to 5.2 my mecanim transitions don't work properly at all.
    I have a 2d character with limbs moving about the z-axis. In 5.2, the transitions aren't smooth.
    The limbs twitch here and there, sometimes jumping to a completely new angles.

    I've loaded a 5.1 build into 5.2 and a 5.2 build into 5.1 to confirm that identical projects behave differently in different versions of Unity.

    I think it may have something to do with how it transitions larger angles greater than 180 degrees.
    It seems as if the angle is less than 180, it makes a smooth transition but if it's over 180, there is a quirky "jump" in the transition.
     
    Last edited: Sep 9, 2015
    Bruce_GMC and Andimator like this.
  2. Photonic4140412

    Photonic4140412

    Joined:
    Apr 23, 2013
    Posts:
    3
    Bruce_GMC likes this.
  3. kingofmyworld324

    kingofmyworld324

    Joined:
    Sep 24, 2013
    Posts:
    10
    I think I am experiencing a similar issue. I have temporarily fixed it by changing the speed of the animation although this is a far from optimal fix.
     
  4. David-Flook

    David-Flook

    Joined:
    Nov 13, 2013
    Posts:
    47
    I've submitted a bug report with the attached project to demonstrate the problem.

    In 5.1, the arm rotates clockwise choosing the shortest angle.
    In 5.2, it attempts to rotate counterclockwise and includes a sudden jump.
     

    Attached Files:

    Bruce_GMC likes this.
  5. HarryCodder

    HarryCodder

    Joined:
    Feb 20, 2015
    Posts:
    75
    There's definitely a problem with blend trees in unity 5.2.

    When testing, I could find a value on the blend parameter where the spine bone would jump from a x-rotation of 331 deg to a x-rotation of 55 deg in one frame (and then back a few frames later).
    In the first animation, the spine bone doesn't rotate at 331 deg and in the second animation it rotates from 350 to 10 deg. I can't figure why it would go to 55 deg, no part of both animations have this bone point this side at all.

    Could not find a way to fix this and blend trees are pretty much unusable in this state.
     
    Armend and Bruce_GMC like this.
  6. flumbatron

    flumbatron

    Joined:
    May 6, 2015
    Posts:
    5
    Yup same issues. When blending, a bone rotates very little and in the wrong direction at first, then quickly jumps to a rotation that is beyond either animation clip, then settles in to the correct end state.

    edit: to clarify this happens in a 2d BlendTree
     
  7. Honikou

    Honikou

    Joined:
    Feb 18, 2013
    Posts:
    91
    Same for me, crossfade didn't work on unity 5.2...
     
  8. sebeisdrache

    sebeisdrache

    Joined:
    Jan 16, 2015
    Posts:
    34
    I having the same problem with blending between layers.
     
  9. TalesGalu

    TalesGalu

    Joined:
    Mar 13, 2013
    Posts:
    3
    Same here. When a transition comes from "Any state" or a empty state, it happens this.
    I made a video showing the transition error:


    It was working fine on 5.1.3, but when I updated to 5.2, I've got a lot of YALM errors and now the transitions look like this.
     
    Bruce_GMC likes this.
  10. Lynxed

    Lynxed

    Joined:
    Dec 9, 2012
    Posts:
    112
    Getting this after upgrade to 5.1.3 -> 5.2. If you have a transition from Linear (1D) Blendtree to watever with "has no exit time", you get errors.

    Character disapears from the screen, when this happens.

    upload_2015-9-13_12-39-48.png
     
    Last edited: Sep 13, 2015
    Bruce_GMC likes this.
  11. TheSniperFan

    TheSniperFan

    Joined:
    Jul 18, 2013
    Posts:
    700
    I'm having trouble with Unity 5.2 too. I play a simple animation when the player is suffering damage or is being healed.

    The way they were set up is simple: They don't contain any information really, but merely a state. For example, the heal "animation" is just a single frame with more bloom. Up until 5.2 the transition that Mecanim did back to the default state worked just fine.
    Now it doesn't interpolate/transition anymore. The screen flashes up, then goes back to normal instantaneously once the "transition" is over.
    Here's a screenshot of the basic setup:

    MecanimProblem5-2.png
     
    Bruce_GMC likes this.
  12. David-Flook

    David-Flook

    Joined:
    Nov 13, 2013
    Posts:
    47
    The issue has been reproduced by the Unity QA team and sent to the developers for resolution.
     
    Bruce_GMC likes this.
  13. adamgryu

    adamgryu

    Joined:
    Mar 1, 2014
    Posts:
    128
    Just wanted to chime in that I'm seeing this issue too. Any time my character transitions from one state to another, some part of the animation jumps to the next rotation without tweening properly. It looks like a gimble lock problem? I'm really hoping for a fast fix on this one!

    EDIT: Is there a link to this bug on the issue tracker? I'd like to vote it up, since it seems pretty urgent.
     
    Last edited: Sep 15, 2015
  14. kognito1

    kognito1

    Joined:
    Apr 7, 2015
    Posts:
    331
    I'll +1 this; many of our animations no longer crossfade correctly (they work fine in 4.3 - 5.1.x). It's unfortunately a showstopper for us.
     
  15. Bruce_GMC

    Bruce_GMC

    Joined:
    Oct 23, 2014
    Posts:
    65
    +1
    We too are getting this issue, and as a result, all of our characters' animations look like dooky.
    We would also like a link to the issue on issue tracker to link with our internal bug reports.
    For now this thread will have to do.
     
  16. McMayhem

    McMayhem

    Joined:
    Aug 24, 2011
    Posts:
    443
    I'd like to throw my hat into the ring and say that I'm having the exact same issue. Only I just transitioned from Legacy to Mecanim after 5.2 so I thought this was just the inherent way Mecanim handles things and figured it was just a piece of crap. However, I'm unable to achieve what I need to do with standard animation and thus am forced to switch to this system. Hopefully this get's fixed soon or some kind of work around is discovered.
     
    Bruce_GMC likes this.
  17. HarryCodder

    HarryCodder

    Joined:
    Feb 20, 2015
    Posts:
    75
    Mecanim is usually great, I think this is just a hiccup that should never have been in a major release.
    An annoying hiccup still.
     
  18. kurozael

    kurozael

    Joined:
    Jan 8, 2014
    Posts:
    4
    I am also having this problem. Is there any official word from the Unity developers on this yet?
     
  19. Andimator

    Andimator

    Joined:
    Sep 18, 2015
    Posts:
    2
    +1 I found this happening when we upgraded from Unity 4 to 5.
     
  20. Sake906

    Sake906

    Joined:
    Mar 27, 2014
    Posts:
    12
    I had to downgrade to 5.1.3. This problem is too obnoxious.
     
  21. HarryCodder

    HarryCodder

    Joined:
    Feb 20, 2015
    Posts:
    75
    Yeah this problem makes Unity 5.2 unusable for anyone using mecanim.
    Anyway, I just tested it in 5.2.0p1 and it wasn't fixed.
     
    Bruce_GMC likes this.
  22. Ghikya

    Ghikya

    Joined:
    Jan 18, 2014
    Posts:
    4
    Yes, sadly the problem wasn't fixed in 5.2.0p1
     
    Bruce_GMC likes this.
  23. any_user

    any_user

    Joined:
    Oct 19, 2008
    Posts:
    368
    Have the same problem, all my animated characters look broken now. Would be great to know if there's a fix coming soon..
     
    Bruce_GMC likes this.
  24. WendelinReich

    WendelinReich

    Joined:
    Dec 22, 2011
    Posts:
    226
    @Mecanim.Dev I think such a large and confirmed issue should be acknowledged in the patch notes under "known issues". As of 5.2.0p1, it is not...
     
    dreasgrech and Bruce_GMC like this.
  25. Bruce_GMC

    Bruce_GMC

    Joined:
    Oct 23, 2014
    Posts:
    65
    I sent Nintendo an email to make sure that they are aware of this issue before they decide to make 5.2.0f3 a version capable of creating masters...

    I thought 5.2 would be good enough to keep us from updating the editor any more but it's now so bad that I have to grab the newest updates still... Dang
     
  26. McMayhem

    McMayhem

    Joined:
    Aug 24, 2011
    Posts:
    443
    I don't doubt that, though I was starting to before I knew it was an issue and not just a design flaw. The only other time I had used Mecanim was for the uGUI animation state handling. The smoothness and quality of that experience is partially what led me to switch to Mecanim from Legacy in the first place. I was really disappointed after seeing all these issues (particularly with blending animations across multiple layers as this is one of the easiest things to do in legacy animation handling), but I am glad to hear that it is not actually just how the design works. Hopefully we'll get some information at least on when this particular issue might be fixed.
     
  27. franktinsley

    franktinsley

    Joined:
    Jul 1, 2010
    Posts:
    130
    Just popping in to say that 5.2.0f1 caused a problem with one of our animation controllers that 5.2.0p1 fixed. Looks like it wasn't the same issue that others are having but if you're experiencing mecanim problems I do have to recommend trying 5.2.0p1 just in case it does fix your particular issue.
     
  28. adamgryu

    adamgryu

    Joined:
    Mar 1, 2014
    Posts:
    128
    Just going to add that I updated to 5.2.0p1 today, and the issue isn't fixed for me. It might have also introduced another bug where the animator does not update on the first frame after a prefab is instantiated, which is annoying for "transition-in" animations.

    On the bright side, it fixed the bug where the Unity Editor state gets messed up if you Ctrl-S while editing an animation.
     
  29. Bruce_GMC

    Bruce_GMC

    Joined:
    Oct 23, 2014
    Posts:
    65
    I updated one of our machines and am confirming that the issue is still not fixed.
     
  30. Doddler

    Doddler

    Joined:
    Jul 12, 2011
    Posts:
    252
    I'm using an animator with only a single animation where the only thing animated is the scene active state of the elements, and it's still bugging out for me. When starting the animation it looks like it's starting the first frame of animation on some weird random state. In my case I can just use a legacy animator, but it's a pretty serious bug to have lying around.
     
  31. Lynxed

    Lynxed

    Joined:
    Dec 9, 2012
    Posts:
    112
    Can confirm: 5.2.0 p1 - it's not fixed. I still have the

    upload_2015-9-19_11-18-4.png
    right at the end of transition from a linear blend tree with "Has exit time" set to false.
     
  32. moco2k

    moco2k

    Joined:
    Apr 29, 2015
    Posts:
    294
    I'm also experiencing issues with suttering animator state transitions - they are not smooth and not properly interpolated (Unity 5.2.0p1 (64-bit)).
     
  33. mmortall

    mmortall

    Joined:
    Dec 28, 2010
    Posts:
    89
    manutoo likes this.
  34. manutoo

    manutoo

    Joined:
    Jul 13, 2010
    Posts:
    367
    @mmortall,
    thanks to have pointed that out.

    It seems it's fixed in 5.2.1 .

    Now we just have to hope it'll be released soon...

    Got a big show-stopper for now... Maybe I'll have to reinstall 5.1 as I can't afford to wait more than a couple of days... :(
     
  35. dCoding

    dCoding

    Joined:
    Sep 9, 2014
    Posts:
    26
    Glad to hear it is fixed in 5.2.1; hopefully that is imminent.

    I went from 5.1.3 to 5.2.0p1 and wondered why my menus suddenly jumped into place instead of smoothly sliding in and out as before!
     
  36. Gizmoi

    Gizmoi

    Joined:
    Jan 9, 2013
    Posts:
    327
    I'm not sure if it's the same issue, but I have a problem where my animations don't snap to the first frame of the first animation when spawned in.
    I use Mecanim for my UI animations, in 5.1 they immediately play the first frame of the animation and hide all my UI. In 5.2 is appears for a frame before the animation kicks in.
     
  37. Mecanim-Dev

    Mecanim-Dev

    Unity Technologies

    Joined:
    Nov 26, 2012
    Posts:
    1,675
  38. Bruce_GMC

    Bruce_GMC

    Joined:
    Oct 23, 2014
    Posts:
    65
    We have decided that we will update but that means I have to wait for the office to clear out tonight, can anyone confirm this fixed?
     
  39. dCoding

    dCoding

    Joined:
    Sep 9, 2014
    Posts:
    26
    Unfortunately my problem remains exactly the same with 5.2.1f1. My UI menu which smoothly moves from offscreen to onscreen (or vice versa) in 5.1.3, remains motionless until about 75% of the way through the animation when it suddenly jumps into a new position, but then doesn't complete the remaining 25%.

    To make that clearer, let's say I have it going from X position -600 (offscreen) to 0 (onscreen) over the course of 1 second, so it should move 10 units per 60th of a second. What actually happens is that the Rect Transform is updating correctly - I can see it going from -600 to 0 in even steps - but the position of the actual GameObject onscreen is not updating, and it remains in the original position. That is until it gets to roughly 75% of the way through the animation, and then the GameObject position onscreen is updated to match the Rect Transform (so in this case it jumps from -600 to about -150) - but after that the GameObject doesn't update onscreen anymore to get to -600 (although the Rect Transform does).

    Hopefully that did make it clearer and not more complicated! But as I say, all works fine in Unity 4.3, 5.0 and 5.1, it is only in 5.2 that it is broken.
     
    Bruce_GMC likes this.
  40. David-Flook

    David-Flook

    Joined:
    Nov 13, 2013
    Posts:
    47
    The specific bug for which this thread was started (transitions) is not fixed in 5.2.1f1.
     
    Bruce_GMC and McMayhem like this.
  41. Bruce_GMC

    Bruce_GMC

    Joined:
    Oct 23, 2014
    Posts:
    65
    It's true, dCoding's response convinced me to update and I am confirming that the issue I recorded in the image above propagates to 5.2.1f1.
     
  42. pierrepaul

    pierrepaul

    Unity Technologies

    Joined:
    Jun 19, 2012
    Posts:
    162
    Hi guys.

    We definitively did fix some part of the problem

    -> I have tested with David Flook's project that was posted above and it is fixed.

    We would like you guys to post simplified versions of your project here, so we can see what is happening and making sure that this is fixed once and for all.

    Thanks!
     
    Bruce_GMC likes this.
  43. ShinAli

    ShinAli

    Joined:
    Sep 24, 2011
    Posts:
    8
    Would it be okay to PM you a link to a repro project?
     
  44. David-Flook

    David-Flook

    Joined:
    Nov 13, 2013
    Posts:
    47
    Strange. I just retested the sample project I submitted to the bug report and it's still not working in 5.2.1f1.
    I crossed checked the project in 5.1.2f1 and it works as expected.

    Maybe it's fixed in the patch release?

    Dave
     
    Last edited: Sep 22, 2015
    Bruce_GMC likes this.
  45. manutoo

    manutoo

    Joined:
    Jul 13, 2010
    Posts:
    367
    Just installed 5.2.1f1 ; it is not fixed : my mobs are still jerking around... o_O

    So I installed 5.1.3p3 and my mob animations now look ok... :rolleyes:
     
    Bruce_GMC likes this.
  46. any_user

    any_user

    Joined:
    Oct 19, 2008
    Posts:
    368
    I can also confirm it's *not* fixed in 5.2.1
     
  47. Gizmoi

    Gizmoi

    Joined:
    Jan 9, 2013
    Posts:
    327
    Same here.
     
  48. HarryCodder

    HarryCodder

    Joined:
    Feb 20, 2015
    Posts:
    75
    It's not fixed in 5.2.1 for us either.
    Will do a bug report when I have more time.
     
  49. pierrepaul

    pierrepaul

    Unity Technologies

    Joined:
    Jun 19, 2012
    Posts:
    162
    Please post bug numbers here. I want us to fix this asap.
     
    hammil and Bruce_GMC like this.
  50. Bruce_GMC

    Bruce_GMC

    Joined:
    Oct 23, 2014
    Posts:
    65
    Hey PierrePaul
    I just built a project and submitted it.
    Case #729939 -- "Unity 5.2 Mecanim Transitions not working the same as 5.1"

    Thank you for looking in to this for us!!!
    <3

    PS- If you need anything from me, please email me!!
     
    Last edited: Sep 23, 2015
unityunity