Sprite with box collider gets stuck on nothing
I have a controlled sprite using a rigidbody 2D and AddForce. For some reason the sprite seems to get stuck when there is nothing to get stuck on. Force is still being applied to the sprite but it refuses to move.
The rigidbody 2D is set to "Fixed Angle". If I remove this then the character will keep moving past these points, but flip 90 degrees when it hits one of them.
The location this happens is random but the following screen is from one of these times.
As you can see, the ground (also sprites) have a rigidbody 2D attached but there is no intersection or collision that would prevent movement. If the character jumps over this section then I can move around again (even over the same spot it got stuck initially).
Here is another screen from a 3D perspective
Answer by Rostam24 · Sep 13, 2015 at 11:25 AM
I think someone else had a similar problem here: http://forum.unity3d.com/threads/2d-jump-and-run.350872/#post-2272386
And here: http://answers.unity3d.com/questions/607080/colliders-2d-apparently-touch-each-other-even-if-t.html
Does this apply to you as well?
Thanks! I followed the advice of using edge colliders rather than box colliders and it works fine. I did see slight changes in position for the box colliders when zoo$$anonymous$$g in as far as I could but even fixing that didn't work. Edge colliders from now on :P
Your answer
![](https://koobas.hobune.stream/wayback/20220612033553im_/https://answers.unity.com/themes/thub/images/avi.jpg)