Hi everyone,
I wanted to test if two sprites are overlaping withouth physics2d. Sprites are of a different shape.
I found this function in phaser docs. If I understand right, it should check if first sprite overlaps given object, in my case another sprite.
Phaser.Sprite.overlap(displayObject) : boolean;
I use this like
if (player1.overlap(player2)) ... else ...
where both players are sprites. Am I using this wrong, or this function is deprecated because I get an error that this function does not exist.
If is possible to check overlap with this function please tell, because i made a project without physics2d and i don't want to make a lot of changes now.
Thanks ahead.