Search code examples
physicsjs

Is it possible to create a concave polygon in PhysicsJS?


I know we are able to create a convex polygon. How about concave polygon? Is it possible to combine two convex polygons then group them to form a concave one? I know Box2D can do that.


Solution

  • Not yet. Creating concave polygons will involve decomposing them into convex polygons and creating a composite body with them. Composite bodies are an upcoming feature. So unfortunately you'll have to wait a bit.