Fixed world drag support and other input modifications.

This commit is contained in:
Richard Davey
2013-06-07 07:35:28 +01:00
parent 730594835a
commit a30762ed8c
37 changed files with 1078 additions and 435 deletions
+4 -4
View File
@@ -258,7 +258,7 @@ module Phaser.Components.Sprite {
}
else
{
return RectangleUtils.contains(this.sprite.worldView, pointer.scaledX, pointer.scaledY);
return RectangleUtils.contains(this.sprite.worldView, pointer.worldX(), pointer.worldY());
}
}
@@ -279,10 +279,10 @@ module Phaser.Components.Sprite {
}
else if (this._pointerData[pointer.id].isOver == true)
{
if (RectangleUtils.contains(this.sprite.worldView, pointer.scaledX, pointer.scaledY))
if (RectangleUtils.contains(this.sprite.worldView, pointer.worldX(), pointer.worldY()))
{
this._pointerData[pointer.id].x = pointer.scaledX - this.sprite.x;
this._pointerData[pointer.id].y = pointer.scaledY - this.sprite.y;
this._pointerData[pointer.id].x = pointer.x - this.sprite.x;
this._pointerData[pointer.id].y = pointer.y - this.sprite.y;
return true;
}
else