You can now use the hitArea property on Sprites and Image objects. hitArea can be a geometry object (Rectangle, Circle, Polygon, Ellipse) and is used in pointerOver checks.

This commit is contained in:
photonstorm
2014-02-07 17:14:10 +00:00
parent 890e52008a
commit bc3a3fd43d
11 changed files with 417 additions and 18 deletions
+2 -1
View File
@@ -40,7 +40,8 @@ Phaser.GameObjectFactory.prototype = {
},
/**
* Create a new Image at the given coordinates, using the cache key and frame if set.
* Create a new `Image` object. An Image is a light-weight object you can use to display anything that doesn't need physics or animation.
* It can still rotate, scale, crop and receive input events. This makes it perfect for logos, backgrounds, simple buttons and other non-Sprite graphics.
*
* @method Phaser.GameObjectFactory#image
* @param {number} x - X position of the image.