Detect stuck dynamic body

General discussion about Box2D tutorials
Post Reply
kyle.bong2@gmail.com
Posts: 41
Joined: Thu May 29, 2014 5:01 am

Detect stuck dynamic body

Post by kyle.bong2@gmail.com »

Hi all, Anyone know best way to detect when dynamic bodies are stuck inside/between static bodies?? Please see screenshot. Any hints greatly appreciated.

Thanks!
Attachments
Untitled.png
Untitled.png (20.03 KiB) Viewed 19917 times
iforce2d
Site Admin
Posts: 861
Joined: Sat Dec 22, 2012 7:20 pm

Re: Detect stuck dynamic body

Post by iforce2d »

This is very difficult, to the point where I probably would not bother. Better to spend your effort preventing this situation from occurring in the first place, for three reasons:
1. it's easier
2. it should improve player experience to not have things getting stuck to begin with
3. it avoids the question about where to move the stuck body once it is detected
Post Reply