Search Unity

  1. Unity 2019.1 is now released.
    Dismiss Notice

Animator Transition between Quaternion Rotations

Discussion in 'Animation' started by CodePoKE, Sep 12, 2018.

  1. CodePoKE


    May 6, 2015

    I'm trying to create an animation where a single sphere is orbited by multiple smaller spheres that randomly orbit it during the "idle" animation, and move into specific positions for the "fire" animation along a shortest path regardless of their prior position. (The "idle" animation can be interrupted at any point.)

    The sphere's GO hierarchy is setup as follows:

    • Main Sphere
      • Small Sphere Pivot
        // Rotation is animated, so the offset smaller sphere orbits the larger one.
        • Small Sphere Mesh
          // Set at a static Y-offset.
    "Fire" animation: Single keyframe with the smaller spheres in specific positions, by rotating the Pivot.
    "Idle" animation: Multiple keyframes with the smaller spheres moving about, by rotating the Pivot.

    The both animations have all rotations setup with Quaternion based interpolation.
    However, when I create a transition to blend between the two clips, the blend path doesn't seem to be using a shortest path blend.

    More importantly, the spheres tend to jump around as they cross certain positions.
    This is done using Unity 5.5.6 (We're in the end-zone of a large project so we can't upgrade)