Which Components do I need to add or subtract from a dynamic object to make it kinematic in Unity DOTS?
I have a character that moves using kinematics while they’re grounded but swaps to dynamic when they fall off something or jump. They fall just fine when I add a PhysicsGravityFactor
and a PhysicsVelocity
but it passes through objects it should be colliding with.
The physics documentation suggests that it’s because it has no Mass so the physics calculations don’t know whether my character should stop moving or whether the thing it hit should get out of the way.
When I add a PhysicsMass
too however, my character ends up zooming off to an invalid world position. Am I missing a component or is there a rule somewhere about not changing the kinematic/ dynamic-ness of an entity at runtime?