Search Unity

Character unexpectedly stumbling when reaching other GameObject

Discussion in 'Physics' started by hurrikam, May 17, 2020.

  1. hurrikam

    hurrikam

    Joined:
    Jun 15, 2015
    Posts:
    2
    Hi everyone,

    I've imported my character's 3D model into the scene and created a Prefab out of it, so that I can instantiate an entire team of players. When running the game, one of them will run to a GameObject (a ball) in order to start the match.
    The character is moved via animator/scripting and, despite having no Rigidbody attached, it falls backwards (it appears to trip) as soon as it touches the ball. My understanding is that without a Rigidbody attached, a GameObject shouldn't be affected by the physics engine.
    I've also tried attaching a Rigidbody with IsKinematic=true and the relevant Rotation/Position constraints set, but the effect of the collision is still there.

    Am I missing the obvious here?

    Thanks,

    -Diego
     
    Last edited: May 17, 2020
  2. hurrikam

    hurrikam

    Joined:
    Jun 15, 2015
    Posts:
    2
    Mystery solved: the issue was actually in the calculation of the rotation vector at the moment when the character reaches the ball. A reminder about watching out for edge cases.