Parenting character controller to rigidbody - strange behaviour

Hello,

I’ve just discovered strange behaviour for me. When I parented an object with CharacterController to object that contained rigidbody and was not kinematic, I observed that when I apply force to rigidboy (AddForce) and continuously move CharacterController (Move(Vector.Zero)) it didn’t follow its parent. On the other hand, when I removed this Move(Vector.Zero) it followed the object as I expected at the beginning. I wanted to create a vehicle that objects could jump into it and transport to different locations in the world, so parenting crossed my mind at once.

Can anybody explain that behaviour to me?

Regards,

Norbert

Rigidbodies aren’t compatible with CharacterControllers in the way you’re attempting to use them. It’s not a safe or wise practice to mix and match non-kinematic ridibodies with character controllers - the intention is to use one or the other.

If you want to drive the vehicle’s motion using physics, ditch the character controller. If you want to use the controller, but also have the vehicle interact properly with other physics-enabled objects, you’re meant to code force responses to collisions with the vehicle’s collider.