Search Unity

  1. The 2022.1 beta is now available for testing. To find out what's new, have a look at our 2022.1 beta blog post.
    Dismiss Notice

Avoid trigger multiple times?

Discussion in 'Animation' started by dengzijian06, Jan 14, 2014.

  1. dengzijian06

    dengzijian06

    Joined:
    Jan 13, 2014
    Posts:
    5
    I found the trigger parameter very useful. But had a headache in practice:

    For example, if I issue "RunTrigger"+"IdleTrigger", the state will end up with "IdleState". Then if I issue "RunTrigger"+"RunTrigger"+"IdleTrigger", I got "RunState" at the end, which I hope the second "RunTrigger" automatically cancel the first one. I tried method "ResetTrigger", it seems has none effect.

    It may also help, if there is a method "GetTrigger", so that I can check it before the second trigger.

    Any one can help us? Thanks!
     
  2. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    14,232
    It sounds like you're trying to use triggers as per booleans.
     
unityunity