Update question

I’m having a slight problem with my characters moving in weird directions at times when I am pretty sure I’m not moving them. It has made me wonder what Unity does under the hood on collision between capsule colliders/rigid bodies. Is there any direct access of their position that I don’t have access to?

The weirdest part of it all, is that I am setting the characters to a static position every frame in their update, and somehow, they still move. They are colliding with objects, but it doesn’t seem as if they are moving in relation to those objects. Any help would be appreciated, though I think this may be a deeper problem with our code…

Do they move in jerks away from the static position? If that’s the case, then something in your code is moving them after the first one sets their position. Collisions set the position, yes, but if you’re setting it to a static position every frame it would override that.

An easy way to test this would be to set your rigidbody to isKinematic or remove your character controller temporarily. Whatever portion of the code tries to move either will create an error you can check. After all, if nothing is trying to move it, then nothing will make an error.

Eh, it’s a hack I think, but turning on isKinematic made it stop. Of course, now they’re not moving at all. But that’s fine. They are meant to “Block”, lol Thanks for the help!