Search Unity

  1. Looking for a job or to hire someone for a project? Check out the re-opened job forums.
    Dismiss Notice
  2. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

Bug Additive Animations & root transform positions

Discussion in 'Animation' started by Tomer-Barkan, Jul 9, 2020.

  1. Tomer-Barkan

    Tomer-Barkan

    Joined:
    Jul 31, 2012
    Posts:
    144
    I seem to have encountered a bug, unless I'm missing something.

    I have an "Idle" state in which the root transform is at height 0.3. Then I transition into "Walking" state, in which the root transform starts at height 0.6. I expect the root transform to move from 0.3 to 0.6 during the state transition, and then continue animating the "Walking" animation at height 0.6.

    What actually happens, is that if I set the animation layer to "Additive" so I can have a separate layer to control walking and another one to control attack animations - in the transition from "Idle" to "Walking", the height of the root transform doesn't change despite the starting pose of the "Walking" being higher than the idle. If I set the layer to "Override" it works fine.

    Am I missing some checkbox or something, or is this a bug that I should report?

    Thanks
     
  2. Tomer-Barkan

    Tomer-Barkan

    Joined:
    Jul 31, 2012
    Posts:
    144
    Update: Ok, I somehow figured out that Additive animations do not change the pose to that of the first frame when starting the animation, but instead only animate the changes within the clip itself. This is not explained at all in the Unity documentation (https://docs.unity3d.com/Manual/AnimationLayers.html) but luckily some people I asked knew about it.

    So question is, how can we do additive sequenced animations? For example, if I want to have a walking animation that is the base layer, and then I want to play a 3-stage shooting animation on top of that - raise hand -> shoot -> lower hand. Every animation resets to the base pose when it starts, so the shoot animation plays with the hand down despite it being played right after the raise hand animation.

    Any ideas how this can be done? How can I have an animation sequence play as additive on top of a base walking layer?

    Note: Masks are not an option because both animations control many bones, not just legs or just hands.
     
unityunity