Jump to content

moveToPointer when using P2 physics


Recommended Posts

I've been using the old arcade methods like moveToXY, distanceTo, angleTo on P2 sprites successfully so far. I did so inadvertently when upgrading to phaser2, and only realised later. Haven't really seen any issues so didn't bother to try and write my own functions.

I can only guess that the arcade functions I've used rely on elements common to both P2 and Arcade bodies (ie position x y, velocity x y, world x y etc) so it works ok.

But that's just my experience so far. I guess it could break all of a sudden.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...