- Home /
Rigidbody character clips through or jitters on corners.
I have a rigidbody based character that used MovePosition to move around. This works great until i walk into a corner. It seems that anywhere i put two intersecting walls the player has strange behaviors. For example, i have two walls that form a corner with an acute angle, when walking into this corner my player will clip through one of the two walls. However when the angle is obtuse the player jitters when walking into it. My character also seems to do this with slanted ceilings. Does this have something to do with how I move my character? I hope this makes sense i know i didn't explain it very well.
Code: https://pastebin.com/PJjFFxwH
Answer by thedrok_ · Mar 10, 2018 at 02:48 PM
I have managed to fix this issue by setting the velocity of the rigidbody instead of using moveposition. It seems that moveposition does not take collisions into consideration when moving allowing it to be moved inside of a collider. When this happens the collider tries to push it out causing the jittering.
Your answer
![](https://koobas.hobune.stream/wayback/20220612154255im_/https://answers.unity.com/themes/thub/images/avi.jpg)