Search the Community
Showing results for tags 'physics body'.
Found 2 results
Hello. I'm really confused about this, what is really the difference of these 3 enabling method of physics body in Phaser? object.physicsBodyType = Phaser.Physics.ARCADE; game.physics.arcade.enable(object); game.physics.enable(object, Phaser.Physics.ARCADE); Are they really the same?
how to calculate object position for different anchor point?Hi! I want to import an object layer from Tiled map editor into a physics engine ( p2.js ). My problem is that p2.js uses 0.5,0.5 as anchor points, but tiled uses 0,0 (top-left). How can i recalculate it's position so i can give it the proper coordinated for a different anchor point? Any help is very much appreciated! Edit : This is easy with rectangles, but my problem is with rotated polygons.