Search Unity

Animation not playing

Discussion in 'Animation' started by will_brett, Sep 23, 2014.

  1. will_brett

    will_brett

    Joined:
    Feb 16, 2013
    Posts:
    208
    Hi there,

    My mecanim is showing the correct node and that the animation is playing but it is not.

    I have setup a character controller using a nav mesh agent. I then created a simple script that converts the desired speed from the nav mesh agent into a float value which mecanim then uses. I have debugged this and the value is correct.

    My mecanim is setup with idle as default and if "speed" is above 0.1 (float value) then it should play the run animation. When the character moves the correct node is highlighted in mecanim and it shows it as playing the run animation but the character is stood completely still.

    I know the animation is setup correctly for the player as it plays in the preview window...

    Any idea as to what may be wrong?
     
  2. Mecanim-Dev

    Mecanim-Dev

    Joined:
    Nov 26, 2012
    Posts:
    1,675
    does your character stay in Idle or does it go into a relax pose? see below for relax pose

    relaxpose.png

    If it stay in idle, select the run state and make sure that the motion for this state is your run animation.

    Also you can take a look at the asset with the run clip, make sure that the rig type is the same for your idle and your run clip, either generic or humanoid.

    The next step would be to send us a bug report with your project, if you do so, pm me with your case #, I will take a look.

    Best regards,
     
  3. will_brett

    will_brett

    Joined:
    Feb 16, 2013
    Posts:
    208
    ok so I discovered the issue and that was that I had two animators in the scene both trying to do the same thing so it was just bugging out. No idea how I managed this but its all working perfectly now.

    Massive fan of mecanim. Such a powerful tool!
     
  4. Mecanim-Dev

    Mecanim-Dev

    Joined:
    Nov 26, 2012
    Posts:
    1,675
    We are happy that you like it. If you have questions, issues or suggestions do not hesitate to ask them on the forum.

    Best regards,