Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Help with animation

I've made an animation for my game, but it only plays when the object becomes active, which I don't want it to do. I want to fire it on a trigger, which I have, but it says it needs to be a legacy animation. What the hell is a legacy animation and how do I convert my animation to a legacy?!?!

Best Answer

  • MouledouxMouledoux Member
    Accepted Answer

    then have it transition back to the first animation.

    Animation triggers only fire once. So if it's just replaying over and over, you must be setting the trigger again somewhere.


  • Do you have an idle animation? What does your animator look like?

    I suspect this is the only animation on that object at the time. If this is so, you need another animation for their 'default' state. This could just be an empty animation clip. Then for changing animation, in the animator, set a transition from default to your trigger animation. Click on the transition and you can set parameters for it. Give it a 'trigger' parameter, and you can set those in code with 'GetComponent<Animator>().SetTrigger([YOUR TRIGGER NAME HERE]);

  • I did that, but for some reason it only fires once...?

  • do you transition back to the default one?

    is the animation set to loop?

  • how do i do that?

    1. click on the animation in the folders
    2. check 'Loop Time'
  • folders?

  • MouledouxMouledoux Member
    edited June 2020

    like the asset folder.....

    the project tab..

  • oh okay i'll try that thank you :)

  • i did that but now it just constantly plays when i trigger it ;-;

  • do you transition back to the default animation?

    do you not want it to loop?

    is there a 3rd animation you want to play instead?

  • i want it to play once every time i trigger it

  • and then what? just not do anything ever again?

  • no i want it to play every time i trigger it

    but not do anything unless the trigger is active

  • It works! Thank you! It's a little janky, but I can fix that. Thank you so much!!!

Sign In or Register to comment.