Making a homing missile that seeks a target using Arcade Physics in Phaser 3.
Tommy Leung from Ourcade writes about creating effective missiles: " If you are making a space shooter game in Phaser 3 with Arcade Physics and tried to add a homing or target seeking missile then you've probably run into a problem with the physics bounding box.
It doesn't rotate with the GameObject so collisions won't work properly. This is by design
One solution is to use Matter Physics but that could mean changing a lot of existing code. And potentially breaking many things in the process.
There is another option if you can live with a missile that only registers collisions when the tip or front hits a target..."
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