Learn how to slice, splice and cut-up matter physics bodies using Phaser and PolyK.

Posted on 22nd Aug 2019. Follow @phaser_ and get the Phaser World newsletter.


Emanuele Feronato gets all dicey: "Back in 2011 I tried to build a script to slice, split and cut Box2D bodies using AS3.

This happened eight years ago, which represent a couple of centuries or even more in game development.

Back to our days with current technologies, I tried to do it with Phaser and Matter.js. Before you jump to the example and the source code, I have to say the result works like a charm thanks to the awesome PolyK which is seven years old but fortunately geometry doesn’t age like software does.

Thanks to PolyK, now you can slice your physics bodies created with Matter.js in Phaser. This is quite a milestone, because it opens a door leading you to new concepts of HTML5 game design.

Ok, let’s see the example in action."

Read More

Learn to code and lead your intrepid crew on a mission to save The Cloud in TwilioQuest, a PC role-playing game inspired by classics of the 16-bit era. Free forever, and available now for Windows, Mac, and Linux.

The first book on the creation of HTML5 cross platform games using Phaser 3 and other free software.
  • By Emanuele Feronato
  • 155 Pages
  • 28 Source Code Examples
  • Build a complete game from start to finish
  • Cross Platform
  • Scaling for devices
Buy Now