mirror of
https://github.com/wassname/phaser.git
synced 2026-07-18 12:30:44 +08:00
Removed input handler from Graphics as it's just meant to be used as a texture really, if you need input events you can apply Graphics to a Sprite.
You can now create a Physics Body directly via game.physics.createBody(), and Body has been updated so it's no longer always bound to a Sprite. Debug.renderPhysicsBody now works with Rectangles, Lines and multiple Convex shapes. Starting to get the Tiled polyline parsing working nicely. Not too far off a complete tilemap collision.
This commit is contained in:
@@ -854,7 +854,7 @@ Object.defineProperty(Phaser.Sprite.prototype, "physicsEnabled", {
|
||||
{
|
||||
if (this.body === null)
|
||||
{
|
||||
this.body = new Phaser.Physics.Body(this);
|
||||
this.body = new Phaser.Physics.Body(this.game, this, this.x, this.y, 1);
|
||||
this.anchor.set(0.5);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user