Search Unity

  1. Unity 2018.3 is now released.
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. We've updated our Terms of Service. Please read our blog post from Unity CTO and Co-Founder Joachim Ante here
    Dismiss Notice
  4. Want to provide direct feedback to the Unity team? Join the Unity Advisory Panel.
    Dismiss Notice
  5. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice

animations not running after upgrade to 5.2.2

Discussion in 'Animation' started by mogavero, Oct 27, 2015.

  1. mogavero

    mogavero

    Joined:
    Apr 14, 2015
    Posts:
    3
    Hello,
    Fairly new to Unity so I apologize if I'm not describing my situation correctly. My situation is that I upgraded to Unity 5.2.2 yesterday from 5.2.1 and my animations have stopped working when I enable them from a script. If I have an animation active when the scene loads then the animation runs but if I set it active from script it won't run.
    A specific example of this is that I have some a UI Text object which increases in size and fades out when the user touches or mouses down on the screen. After upgrading the Animator controller becomes active but the animation doesn't do anything. While trying to figure out what's going on, if I click the 'Apply Root Motion' checkbox after the animation has been activated, the animation does run. I then tried setting the animation.applyRootMotion to true in the script and I see the checkbox get checked in the editor but the animation does not run.
    Another thing I have noticed is that there is a little dialog box below the animation in Animator editor window which gives statistics like Clip Count: 1 Curves Pos:, Generic: After the animation is activated from script, the information changes to say "Not Initialized"

    Finally, I tried creating a new animation controller and a new animation from scratch and adding it back to my gameobject and got the same results.

    Nothing shows up in the console.

    Am I missing something that should have been configured before that is showing it's ugly head after the 5.2.2 upgrade
     
  2. Mecanim-Dev

    Mecanim-Dev

    Unity Technologies

    Joined:
    Nov 26, 2012
    Posts:
    1,623
    If the same project was working in 5.1 but not in 5.2 it either a new regression or a change in the animator behaviour.

    Could you log a bug with your project and give us some step to reproduce the issue, we will take a look.
     
  3. mogavero

    mogavero

    Joined:
    Apr 14, 2015
    Posts:
    3
    ok, thanks. I submitted a bug report. I also created a brand new project and deployed it to a device as well. I get the same results in both those scenarios as well.
     
  4. mogavero

    mogavero

    Joined:
    Apr 14, 2015
    Posts:
    3
    In case anyone is looking at this...i downgraded back to Unity to 5.2.1 and my animations work again.
     
  5. mattscott

    mattscott

    Joined:
    Jul 12, 2013
    Posts:
    10
    I'm seeing this too with animations created in the Unity Editor. If I scrub through the anim in the Animation Editor, it all looks correct. The animation states look like they're playing in the Animator Window, but it's not playing in the Editor / Game
     
  6. msureka83

    msureka83

    Joined:
    Nov 28, 2014
    Posts:
    30
    Yes, with 5.2.2 Unity is crashing at the place where my animation should play. It just crashes and does not give any errors on the console. On XCode while testing on device it crashes at PrepareAnimationEvents(), hence the crash is surely related to some form of animation handling.
    EDIT: It was working fine on 5.2.1
     
    Last edited: Oct 29, 2015
  7. jagttt

    jagttt

    Joined:
    Nov 2, 2012
    Posts:
    10
    @Mechanim.Dev

    We've encountered the same issue on 5.2.2p1. I can't reproduce it in a standalone project, but I'm pretty sure it's related to setting animator.speed to 0 during transition. When the bug happens it would make the animator into a state like attached screenshot, where the transition is played in the animator window, but the FROM state isn't exiting, and the TO state is playing in the animator window but not in the game/editor view. The animator is stuck at the end of the FROM state.

    If I disable setting animator speed to 0 entirely the issue will be gone. But the whole thing is working on 5.1.2.
    I'll try to get a small demo project later, hope this info can help you locate the issue.

    Cheers.
     

    Attached Files:

  8. Topaz_

    Topaz_

    Joined:
    Dec 23, 2014
    Posts:
    3
    Yes, experiencing this too. My menu has tabs which slide in based on a animator.setbool, so I activate them with animator.enabled when I first use the animation. Apparently the first use of animation does not work, but after which the sliding works fine. Can confirm that this has never been an issue, but started occurring as soon as I updated to 5.2.2f1.

    Guessing theres a simple thing that we've overlooked and has recently been fixed, or updated, so if anyone can figure out what this is, it would be greatly appreciated.
     
  9. screenname_taken

    screenname_taken

    Joined:
    Apr 8, 2013
    Posts:
    613
    @Mecanim.Dev I'm also using the fast and dirty "activate the animator component for a single animation" to play.
    Stopped working since 5.2.2.
    Currently on 5.2.2p1
     
  10. Mecanim-Dev

    Mecanim-Dev

    Unity Technologies

    Joined:
    Nov 26, 2012
    Posts:
    1,623
    Please log a new bug if you see some regression when upgrading to a new version, even if you think it the same bug it may not be related.
     
    Topaz_ likes this.
  11. screenname_taken

    screenname_taken

    Joined:
    Apr 8, 2013
    Posts:
    613
    Bug case is 740895. There are instructions to see the bug easily.
     
  12. Topaz_

    Topaz_

    Joined:
    Dec 23, 2014
    Posts:
    3
    Downgraded to temporarily solve the problem (to 5.2.1), unfortunately that means it doesn't have the new Xcode plugins :) yolo
     
  13. skalev

    skalev

    Joined:
    Feb 16, 2012
    Posts:
    264
    Seems like we are experiencing the same issue. We get a forced editor crash, without any dump or bug reporting tool coming up. When I attach Visual Studio to the actual Unity.exe process, (developing on Window, with x64 editor) I can catch the exception before unity is closed. Below are the stack trace and disassembly windows.

    crashdiss.jpg crashstack.jpg crasherror.jpg
     
  14. skalev

    skalev

    Joined:
    Feb 16, 2012
    Posts:
    264
    I've been able to easily reproduce this in 5.2.2p3 as of today.
    I've submitted a new bug report Case 742678
     
  15. screenname_taken

    screenname_taken

    Joined:
    Apr 8, 2013
    Posts:
    613
    I think this is fixed in 5.3.
     
  16. ArachnidAnimal

    ArachnidAnimal

    Joined:
    Mar 3, 2015
    Posts:
    1,578
    Last edited: Nov 12, 2015
  17. PlayNicelyLtd

    PlayNicelyLtd

    Joined:
    Aug 8, 2013
    Posts:
    2
    Having the same problem. Animators on game objects that have been disabled then re-enabled do not play, and I get the error "Animator not initialized".
     
  18. screenname_taken

    screenname_taken

    Joined:
    Apr 8, 2013
    Posts:
    613
    They said that this will be fixed on 5.3
     
  19. davidosullivan

    davidosullivan

    Joined:
    Jun 9, 2015
    Posts:
    379
    I wish they'd release patches for bugs like this for users who dont have PRO :(
     
  20. Mecanim-Dev

    Mecanim-Dev

    Unity Technologies

    Joined:
    Nov 26, 2012
    Posts:
    1,623
  21. tcossairt

    tcossairt

    Joined:
    Dec 5, 2013
    Posts:
    129
    We are still seeing this crash on 5.3.2p1
     
  22. screenname_taken

    screenname_taken

    Joined:
    Apr 8, 2013
    Posts:
    613
    The latest one is p3.
    My animation issues were fixed with a patch after p1.
     
  23. tcossairt

    tcossairt

    Joined:
    Dec 5, 2013
    Posts:
    129
  24. screenname_taken

    screenname_taken

    Joined:
    Apr 8, 2013
    Posts:
    613
    Well at least my issue was fixed.
     
  25. tcossairt

    tcossairt

    Joined:
    Dec 5, 2013
    Posts:
    129
    Unfortunately we are still seeing the PrepareAnimationEvents crashes even in 5.3.3f1. Is anyone else still seeing these?
     
  26. klightner

    klightner

    Joined:
    Jun 3, 2014
    Posts:
    2
    We are seeing them in Unity 5.3.4p2. They appear fairly randomly, but for us, it looks like it happens right now when we pull an avatar out of the dead pool and restart it.
     
  27. klightner

    klightner

    Joined:
    Jun 3, 2014
    Posts:
    2
    Still crashing in 5.3.4p4
     
  28. Waqas-Anwar

    Waqas-Anwar

    Joined:
    Feb 2, 2015
    Posts:
    26
    I made an animation in Unity 5.6.0 and upgraded unity to Unity 2017.3.1f1 , now the animation is not working. I also tried playing in 5.6.1. Seems like the animation will only work in the version it was made in. Do we have a solution for this ?
    @Mecanim-Dev
     
  29. umkhan93

    umkhan93

    Joined:
    Jan 3, 2018
    Posts:
    4
    I'm having the same problem