Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

CrossFade issues

Discussion in 'Animation' started by Toack, Apr 9, 2014.

  1. Toack

    Toack

    Joined:
    Dec 18, 2006
    Posts:
    107
    CrossFade() is not finishing my animations but Play() does.

    Imagine I have two animations, Open and Close

    Open rotates my object (a door) from 0 to 90 while Close rotates my object (the same door) from 90 to 0.

    If I use Play(), then Close finishes when it get to 0, but if I use CrossFade(), the door stops between 0 and 10, sometimes at 5.5, sometimes at 2.3, totally random. After several tests I can't find the reason, the only solution I found was to use WrapMode.ClampForever but the animation never stops, and I think this consumes CPU if I have like 20 doors per scene, right ?.

    Please help, using Play() makes the transitions instant, which is not a good effect.
     
  2. Toack

    Toack

    Joined:
    Dec 18, 2006
    Posts:
    107
    No one? it's driving me nuts...