Global

Methods

canUseNewCanvasBlendModes() → {Boolean}

Checks whether the Canvas BlendModes are supported by the current browser

Source:
Returns:

whether they are supported

Type
Boolean

getBounds() → {Phaser.Rectangle}

Returns the framing rectangle of the ellipse as a Phaser.Rectangle object.

Source:
Returns:

The framing rectangle

Type
Phaser.Rectangle

getNextPowerOfTwo(number) → {Number}

Given a number, this function returns the closest number that is a power of two this function is taken from Starling Framework as its pretty neat ;)

Parameters:
Name Type Description
number Number
Source:
Returns:

the closest number that is a power of two

Type
Number

hex2rgb(hex)

Converts a hex color number to an [R, G, B] array

Parameters:
Name Type Description
hex Number
Source:

hitTest(displayObject)

Tests if the current mouse coordinates hit a sprite

Parameters:
Name Type Description
displayObject DisplayObject

The displayObject to test for a hit

Source:

rgb2hex(rgb)

Converts a color as an [R, G, B] array to a hex number

Parameters:
Name Type Description
rgb Array
Source:
Phaser Copyright © 2012-2014 Photon Storm Ltd.
Documentation generated by JSDoc 3.3.0-dev on Mon Feb 24 2014 12:11:34 GMT-0000 (GMT) using the DocStrap template.