quinton-ashley / p5play

JavaScript game engine that uses q5.js/p5.js for graphics and Box2D for physics.
https://p5play.org
GNU Affero General Public License v3.0
667 stars 184 forks source link

Bug in 3.15 when trying to detect a group sprite overlapping with a sprite #275

Closed rahji closed 1 year ago

rahji commented 1 year ago

It seems like myGroup.overlapping(aSprite) is not working in 3.15. It works fine in 3.14.

Please see the repo here for an example I made to show the issue: https://github.com/rahji/broken_overlappinggroup

quinton-ashley commented 1 year ago

Thanks for reporting but the issue has already been fixed in the latest version, v3.15.7. I tested it and it worked!

rahji commented 1 year ago

Very strange. That's the version in the repo I linked as far as I can tell. I downloaded again to be sure and it's the same problem. Were you able to clone the repo and see the issue?

quinton-ashley commented 1 year ago

oh wait sorry, I didn't realize that your index.html linked to v3.14. I do see the issue now.

rahji commented 1 year ago

glad I'm not totally crazy! 😆

quinton-ashley commented 1 year ago

Ah there was a problem with the sprite.addDefaultSensors function which is used internally the first time an overlap check occurs. The problem only affected sprites which had their collider type changed to "none" (not set in the constructor). Thanks for reporting the issue!

Fixed in v3.15.8

rahji commented 1 year ago

Thanks!