Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice

Root Motion with Scripted Falling or Falling Animation?

Discussion in 'Animation' started by Deleted User, Mar 10, 2020.

  1. Deleted User

    Deleted User

    Guest

    Hello,
    Having a hard time here. I love root motion, so I am sticking with it. But I have to find a way to make this character fall or I'm going to lose my mind. LOL!

    Please don't send me to a blob of code.
     
  2. lightbug14

    lightbug14

    Joined:
    Feb 3, 2018
    Posts:
    447
    Hi, maybe you could create a StateBehaviour for that specific state (the falling state) and implement the OnStateMove method. This will not apply the root motion to your avatar, so you can manage the rigidbody vertical velocity as you want.

    AFAIK OnAnimatorMove (for a monobehaviour) will do the same for all the states.