fitness23 Posted June 9, 2015 Share Posted June 9, 2015 I am enable to detect 2 overlapping objects for some reason, but I've always been able to do it before. The page in question is here = http://www.andy-howard.com/prison-purge/index.html I have set arcade physics = this.game.physics.startSystem(Phaser.Physics.ARCADE); I have also enabled physics on the 2 objects in questions: this.game.physics.arcade.enable(this.feet);andthis.game.physics.arcade.enable(this.walkingBoundaries); And then in the update function I have set: this.game.physics.arcade.overlap(this.feet, this.walkingBoundaries, stopPlayer, null, this); I'd just like to know when the players feet overlap with the green line but it doesn't seem to work.The only things that I am doing differently compared to what I normally do it overlapping with a line instead of a sprite, and also the movement is based on a tween not velocity - but I don't think that should make any difference. Link to comment Share on other sites More sharing options...
AzraelTycka Posted June 9, 2015 Share Posted June 9, 2015 Hello,I think physics and tweens kinda don't go well together if you are not changing physics values (velocit, ...). You can check overlaping by tween movement (change in x/y) in other way see phaser example. EDIT:Try setting movement by body.velocity and check wheter or not your overlap goes off to, if it doesn't work then there is a problem elsewhere. Link to comment Share on other sites More sharing options...
Recommended Posts