Best way to move a physics character around? First person / Third person snappy movement.

Hello,

I am trying to figure out the best way to move a character using DOTS physics.

I have tried using “Translation”, but the character always bounces off the walls like a spring board…then keeps sliding indefinitely in the opposite direction, which doesn’t work.

I have tried setting physics velocity, but I do not like the way this will override the base physics contributors (like gravity, possibility of adding explosive forces, etc).

I have also tried using additive velocity along with using impulse forces, but then I have to play around with the drag and other settings to make the character not look like its sliding around on ice…which ends up with an unsatisfying feel.

Is there a solid Physics movement strategy like translation that will also not have the player bounce and glitch when you run a player into a wall…while also having the base functionality of the physics system?

Thanks,

This is…non-trivial. There’s an example character controller in the Physics samples, and they are setting the velocity directly. The velocity is calculated based on the results of a couple collider casts in the utilities. Looks like gravity and collision response are all manual. That example used to be much less sane, and I’m pleased to see it updated, haha. It’s a lot of work to get something nice.

By the way, there is a dedicated physics forum.

1 Like

Damn. Was hoping to not have to manually configure the velocity for every situation. Just want to push a simple controller around while it interacts with physics…maybe some manual stuff here and there.

Oh well. Thanks for the reply. Guess I will stick to playing around with the damping settings and whatnot.

Also thanks for the physics forum link. will ask there in the future.

1 Like