Slice Physics Bodies with Matter.js and Phaser
Slicing, splitting, and cutting bodies are common events on game designs. You could build a lot of games with this mechanic.
Slice bodies using a source code created with Phaser, Matter.js, and PolyK’s slice method. The event is performed once you draw a starting point and then an endpoint. Drag the mouse to draw the line and cut an object.
You could also cut multiple objects with this source code.
Check out the rest of the code here.