Search Unity

  1. 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
  2. Ever participated in one our Game Jams? Want pointers on your project? Our Evangelists will be available on Friday to give feedback. Come share your games with us!
    Dismiss Notice

Parent Contraints evalutation/execution order and IK.

Discussion in 'Animation' started by Kesh, Jan 31, 2020.

  1. Kesh

    Kesh

    Joined:
    Jan 13, 2014
    Posts:
    21
    Hello,

    Is there any way to adjust the evaluation or execution order of Parent Constraints? I have a character that modifies IK through scripting after the Update loop, and Parent Constraints ignores the updated transforms after IK in Unity 2019+. It seems to only evaluate the Animator stream. In 2018 LTS the order is correct and applies Parent Constraints after my IK. Is there any way to correct this in 2019.3 ?
     
  2. Kesh

    Kesh

    Joined:
    Jan 13, 2014
    Posts:
    21
    bump
     
  3. simonbz

    simonbz

    Unity Technologies

    Joined:
    Sep 28, 2015
    Posts:
    131
    Hi,

    Chances are you are referring to the following issue we addressed a while ago:
    https://issuetracker.unity3d.com/is...-function-does-not-yield-the-correct-position

    The issue was that constraints were applied after the LateUpdate callback and thus there was no way to run game logic to get the end result of animation (animation + constraints).

    If you want to modify the animator IK before the constraints have been applied, you can use the OnAnimatorIK callback instead.

    You can refer to the following for a detailed explanation of the execution order in Unity:
    https://docs.unity3d.com/Manual/ExecutionOrder.html
     
unityunity