Nape debug drawer

As I’ve been pointed towards Nape in the everlasting search towards a faster physics engine, I’ve started playing with it this evening. The playing stopped real fast, when I found out that there is no standard drawing class, which will draw the whole Space for you (for all you Box2D fans, Space = b2World). In the Nape debug workflow you assign a Sprite to a Shape. Not only did I find this cumbersome, but I don’t think a lot of DisplayObjects on stage will do much good for performance.

So instead of spending my evening playing with the actual engine, I’ve spent my few hours coding a class that draws what is going on. It hasn’t been tested that much, only a few simple bodies, but I’ll work on it later this week. If anybody would like to use it, you’re free to do so. Please leave any feedback if you do so.

Blog entry

NapeDraw class