bambieee Posted November 30, 2018 Share Posted November 30, 2018 Hi guys, Is there a way for collision detection without using Matter or any physics. It would be great if I can use the special shape vector body, but I will happy for a rectangular body as well. Or if I am using physics, how can I avoid my sprite rebounding from other sprites. I just want to detect when they overlapped each other. I am using this: this.matter.world.on('collisionstart', function (event, bodyA, bodyB) {} Thanks Link to comment Share on other sites More sharing options...
bambieee Posted November 30, 2018 Author Share Posted November 30, 2018 I think the setSensor() is just for this. Its working now. Link to comment Share on other sites More sharing options...
ERBarratt Posted December 1, 2018 Share Posted December 1, 2018 I just made a system that uses lines and points to do this: https://github.com/erbarratt/phaser-pointline Working demo: http://sxbx.mountalpine.net (The dog is an overlapper with the player). Link to comment Share on other sites More sharing options...
samme Posted December 2, 2018 Share Posted December 2, 2018 All of the Phaser Geom classes have contains tests. Link to comment Share on other sites More sharing options...
Recommended Posts