mirror of
https://github.com/wassname/phaser.git
synced 2026-09-09 11:28:47 +08:00
Updated World vastly. No longer extends p2.World due to a few vars we can't alias cleanly, adds in lots of new helper methods.
Ready for Materials and Constraints. InversePointProxy is for aliasing a p2 typed array when the values need reversing before applying (gravity for example).
This commit is contained in:
+2
-2
@@ -70,7 +70,7 @@ Phaser.Physics.Body = function (game, sprite, x, y, mass) {
|
||||
if (sprite)
|
||||
{
|
||||
this.setRectangleFromSprite(sprite);
|
||||
this.game.physics.addBody(this.data);
|
||||
this.game.physics.addBody(this);
|
||||
}
|
||||
|
||||
};
|
||||
@@ -399,7 +399,7 @@ Phaser.Physics.Body.prototype = {
|
||||
|
||||
if (this.data.world !== this.game.physics)
|
||||
{
|
||||
this.game.physics.addBody(this.data);
|
||||
this.game.physics.addBody(this);
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user