File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -844,10 +844,10 @@ Phaser.Input.prototype = {
844844 {
845845 return ( displayObject . hitArea . contains ( this . _localPoint . x , this . _localPoint . y ) ) ;
846846 }
847- else if ( displayObject instanceof PIXI . Sprite )
847+ else if ( displayObject instanceof Phaser . TileSprite )
848848 {
849- var width = displayObject . texture . frame . width ;
850- var height = displayObject . texture . frame . height ;
849+ var width = displayObject . width ;
850+ var height = displayObject . height ;
851851 var x1 = - width * displayObject . anchor . x ;
852852
853853 if ( this . _localPoint . x >= x1 && this . _localPoint . x < x1 + width )
@@ -860,10 +860,10 @@ Phaser.Input.prototype = {
860860 }
861861 }
862862 }
863- else if ( displayObject instanceof Phaser . TileSprite )
863+ else if ( displayObject instanceof PIXI . Sprite )
864864 {
865- var width = displayObject . width ;
866- var height = displayObject . height ;
865+ var width = displayObject . texture . frame . width ;
866+ var height = displayObject . texture . frame . height ;
867867 var x1 = - width * displayObject . anchor . x ;
868868
869869 if ( this . _localPoint . x >= x1 && this . _localPoint . x < x1 + width )
You can’t perform that action at this time.
0 commit comments