diff --git a/CHANGELOG.md b/CHANGELOG.md index 3bdc48406..bd653d7d6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,61 @@ # Change Log +## Version 2.1.2 - "Whitebridge" - 9th October 2014 + +### New Features + +* StateManager.unlink will null all State-level Phaser properties, such as `game`, `add`, etc. Useful if you never need to return to the State again. +* Cache.removeImage has a new parameter: `removeFromPixi` which is `true` by default. It will remove the image from the Pixi BaseTextureCache as well as from the Phaser Cache. Set to false if you don't want the Pixi cache touched. +* Group.ignoreDestroy boolean will bail out early from any call to `Group.destroy`. Handy if you need to create a global Group that persists across States. +* Loader can now natively load XML files via `load.xml`. Once the XML file has loaded it is parsed via either DOMParser or ActiveXObject and then added to the Cache, where it can be retrieved via `cache.getXML(key)`. +* Cache now has support for XML files stored in their own container. You can add them with `cache.addXML` (typically this is done from the Loader automatically for you) and get them with `cache.getXML(key)`. There is also `cache.checkXMLKey(key)`, `cache.checkKeys` and `cache.removeXML(key)`. +* Rectangle.aabb is a new method that will take an array of Points and return a Rectangle that matches the AABB (bounding area) of the Points (thanks @codevinsky #1199) +* AudioSprite support is now built into the Loader and SoundManager. AudioSprites are like sprite sheets, only they consist of a selection of audio files and markers in a json configuration. You can find more details at https://github.com/tonistiigi/audiosprite (thanks @codevinsky #1205) +* Point.parse will return a new Point object based on the x and y properties of the object given to Point.parse (thanks @codevinsky #1198) +* Sound.fadeOut(duration) will fade the Sound to a volume of zero over the duration given. At the end of the fade the Sound will be stopped and Sound.onFadeComplete dispatched. +* Sound.fadeIn(duration, loop) will start the Sound playing, or restart it if already playing, set its volume to zero and then increase the volume over the duration given until it reaches 1. At the end of the fade the Sound.onFadeComplete event is dispatched. +* Text.addColor allows you to set specific colors within the Text. It works by taking a color value, which is a typical HTML string such as `#ff0000` or `rgb(255,0,0)` and a position. The position value is the index of the character in the Text string to start applying this color to. Once set the color remains in use until either another color or the end of the string is encountered. For example if the Text was `Photon Storm` and you did `Text.addColor('#ffff00', 6)` it would color in the word `Storm` in yellow. +* Text.clearColors resets any previously set colors from `Text.addColor`. +* If you pass a tinted Sprite to `BitmapData.draw` or `BitmapData.copy` it will now draw the tinted version of the Sprite to the BitmapData and not the original texture. +* BitmapData.shadow(color, blur, x, y) provides a quick way to set all the relevant shadow settings, which are then be used in future draw calls. +* Cache.addBitmapData has a new parameter: `frameData` allowing you to pass a `Phaser.FrameData` object along with the BitmapData. +* Cache.getFrameData has a new parameter: `map` which allows you to specify which cache to get the FrameData from, i.e. `Phaser.Cache.IMAGE` or `Phaser.Cache.BITMAPDATA`. +* Sprite.loadTexture if given a BitmapData as the texture will now query the cache to see if it has any associated FrameData, and if so it will load that into the AnimationManager. +* BitmapData.textureLine takes a Phaser.Line object and an image in the image cache. It then accurately draws the image as a repeating texture for the full length of the line. +* AnimationManager.name will now return the `name` property of the currently playing animation, if any. +* Group.filter takes a predicate function and passes child, index, and the entire child array to it. It then returns an ArrayList containing all children that the predicate returns true for (thanks @codevinsky #1187) +* Cache.checkUrl allows you to check if a resource is in the cache based on an absolute URL (thanks @englercj #1221) +* Cache.getUrl gets a resource from the cache based on the absolute URL it was loaded from (thanks @englercj #1221) +* Sound.allowMultiple allows you to have multiple instances of a single Sound playing at once. This is only useful when running under Web Audio, and we recommend you implement a local pooling system to not flood the sound channels. But it allows for one Sound object to play overlapping times, useful for gun effects and similar (#1220) + +### Updates + +* TypeScript definitions fixes and updates (thanks @clark-stevenson @englercj @benjamindulau) +* Added the `sourceRect` and `maskRect` parameters back into `BitmapData.alphaMask` as they were accidentally removed in 2.1 (thanks seejay92) +* jsdoc fixes (thanks @danxexe #1209) +* AnimationParser is now using `value` instead of `nodeValue` when parsing atlas XML files, avoiding Chrome deprecation warnings (thanks @valtterip #1189) +* Color.webToColor restored. Converts a CSS rgba color into a native color value. +* Color.createColor now populates the `color` property of the returned object with the results of `Phaser.Color.getColor`. +* Color.createColor now has a `color32` property with the results of `Phaser.Color.getColor32`. +* Color.hexToColor has been optimised to inline the regex and has moved the createColor call so it now populates the color object fully, not just setting the r,g,b properties. +* Keyboard.PLUS and Keyboard.MINUS have been added to the list of key codes (thanks @VictorBjelkholm #1281) + +### Bug Fixes + +* If Game Objects change their frame, such as with an animated Sprite, and the change goes from a previously trimmed frame to a non-trimmed (full size) one, then the previous trim values were still left active, causing it to glitch (thanks stupot) +* If you called StateManager.start from within a states `init` method which also had a `preload` method it would fail to start the next State. +* StateManager.boot would call start on a State twice if it was added to the game and started before the DOM load had completed. This didn't cause an error but was duplicating function calls needlessly. +* Changing any of the Text properties such as font, lineSpacing and fontSize on a Text object that wasn't already on the display list would cause an updateTransform error. Parent is now checked first in all setters. +* A Timer with a delay value that was a float and not an integer would not loop correctly. Timer delay values are now passed through Math.round to avoid this (thanks @osmanzeki #1196) +* The Loader would incorrectly call `fileComplete` for legacy audio files instead of setting it as a callback, throwing up errors if the audio file failed to load (thanks @spayton #1212) +* The Uint32Array check used in Utils was incorrectly replacing Uint32Array on Safari, causing errors like BitmapData.getPixel32 to fail and other related issues (fixes #1043 and #1197) +* Camera.follow would break if the parent of the Sprite being followed was scaled in any way (thanks @englercj #1222) +* Fixed the 4fv uniform in the Pixelate filter. + +## Version 2.1.1 - "Eianrod" - 11th September 2014 + +Version 2.1.1. of Phaser is an emergency point release. It addresses a potential race condition that could happen in States that tried to change state from the create method but had an empty preloader or pre-cached assets. + ## Version 2.1.0 - "Cairhien" - 9th September 2014 ### New Features diff --git a/README.md b/README.md index 6a6f34fe2..b4b1f34a2 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ Phaser is a fast, free and fun open source game framework for making desktop and mobile browser HTML5 games. It uses [Pixi.js](https://github.com/GoodBoyDigital/pixi.js/) internally for fast 2D Canvas and WebGL rendering. -Version: 2.1.2 "Whitebridge" - Released: in development +Version: 2.1.2 "Whitebridge" - Released: 9th October 2014 By Richard Davey, [Photon Storm](http://www.photonstorm.com) @@ -45,6 +45,22 @@ By Richard Davey, [Photon Storm](http://www.photonstorm.com) ## Welcome to Phaser and What's new in 2.1.2? +Phaser 2.1.2 carries on with our latest round of new features, updates and fixes, demonstrating our commitment to continuously improving our framework and responding to feedback. + +This release adds in a number of new features including Audio Sprite json format support, native loading of XML files, Sound fades, per character Text colours, further updates to BitmapData, the ability to use BitmapData with frames as Sprite textures, Group filter, search the Cache by URL and plenty of updates and bug fixes too - including the death of the pesky getPixel issue on Safari / iOS. + +Internally we are using Phaser in ever larger client based projects. Thousands of lines of code spread across many States and classes, and we're paying close attention to how best to adapt the API to make life easier for those building apps of the size we are. If there are any features you would like to see then now is the time to suggest them, either by email, the forum or github. + +We're also pleased to announce that we have 3 new premium plugins gearing up for launch. They are: + +Phaser Box2D - Adds complete Box2D support directly into Phaser, with lots of help methods, over 50 examples and 5 demo games. + +Phaser Path Manager - Create complex motion paths for Sprites with a lovely visual editor and this new plugin. No longer rely on tweens for motion :) Instead draw a path, with full branch support, path orientation, segment speeds, path events and more. + +Advanced Particle System - The particles included with Phaser are flexible and can create attractive effects. But Advanced Particles is a complete replacement offering professional level particle effects for your games. From multiple render targets, to bitmap caching to all kinds of events, emitters and properties. + +Each plugin will come in a range of versions to suit all budgets and there are more on the way. Please visit the [launch page](http://phaserplugins.launchrock.com) to sign-up for notification as soon as they're ready. + Until then happy coding everyone! And we hope to see you on the forums. ![boogie](http://www.phaser.io/images/spacedancer.gif) @@ -69,9 +85,7 @@ Finally the list of [community authored Phaser Tutorials](http://www.lessmilk.co ## Change Log -Version 2.1.2 - "Whitebridge" - in development - - +Version 2.1.2 - "Whitebridge" - October 9th 2014 ### New Features @@ -123,7 +137,6 @@ Version 2.1.2 - "Whitebridge" - in development * Camera.follow would break if the parent of the Sprite being followed was scaled in any way (thanks @englercj #1222) * Fixed the 4fv uniform in the Pixelate filter. - For details about changes made in previous versions of Phaser see the full Change Log at https://github.com/photonstorm/phaser/blob/master/CHANGELOG.md ![div](http://phaser.io/images/div3.png) diff --git a/docs/AABB.js.html b/docs/AABB.js.html index 8f2f84fda..d8424f26a 100644 --- a/docs/AABB.js.html +++ b/docs/AABB.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -518,7 +526,6 @@ - @@ -548,7 +555,6 @@ * Note: This class could be massively optimised and reduced in size. I leave that challenge up to you. * * @class Phaser.Physics.Ninja.AABB -* @classdesc Arcade Physics Constructor * @constructor * @param {Phaser.Physics.Ninja.Body} body - The body that owns this shape. * @param {number} x - The x coordinate to create this shape at. @@ -1590,7 +1596,7 @@ Phaser.Physics.Ninja.AABB.prototype = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Animation.js.html b/docs/Animation.js.html index 06fb1c226..c1575635a 100644 --- a/docs/Animation.js.html +++ b/docs/Animation.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -552,7 +560,7 @@ * @param {Phaser.Sprite} parent - A reference to the owner of this Animation. * @param {string} name - The unique name for this animation, used in playback commands. * @param {Phaser.FrameData} frameData - The FrameData object that contains all frames used by this Animation. -* @param {(Array.<number>|Array.<string>)} frames - An array of numbers or strings indicating which frames to play in which order. +* @param {number[]|string[]} frames - An array of numbers or strings indicating which frames to play in which order. * @param {number} delay - The time between each frame of the animation, given in ms. * @param {boolean} loop - Should this animation loop when it reaches the end or play through once. */ @@ -1270,6 +1278,7 @@ Object.defineProperty(Phaser.Animation.prototype, 'enableUpdate', { * You could use this function to generate those by doing: Phaser.Animation.generateFrameNames('explosion_', 1, 30, '-large', 4); * * @method Phaser.Animation.generateFrameNames +* @static * @param {string} prefix - The start of the filename. If the filename was 'explosion_0001-large' the prefix would be 'explosion_'. * @param {number} start - The number to start sequentially counting from. If your frames are named 'explosion_0001' to 'explosion_0034' the start is 1. * @param {number} stop - The number to count to. If your frames are named 'explosion_0001' to 'explosion_0034' the stop value is 34. @@ -1347,7 +1356,7 @@ Phaser.Animation.generateFrameNames = function (prefix, start, stop, suffix, zer Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/AnimationManager.js.html b/docs/AnimationManager.js.html index 9d80a667b..3ab093beb 100644 --- a/docs/AnimationManager.js.html +++ b/docs/AnimationManager.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -621,6 +629,11 @@ Phaser.AnimationManager.prototype = { */ loadFrameData: function (frameData, frame) { + if (typeof frameData === 'undefined') + { + return false; + } + if (this.isLoaded) { // We need to update the frameData that the animations are using @@ -1035,6 +1048,23 @@ Object.defineProperty(Phaser.AnimationManager.prototype, 'paused', { }); +/** +* @name Phaser.AnimationManager#name +* @property {string} name - Gets the current animation name, if set. +*/ +Object.defineProperty(Phaser.AnimationManager.prototype, 'name', { + + get: function () { + + if (this.currentAnim) + { + return this.currentAnim.name; + } + + } + +}); + /** * @name Phaser.AnimationManager#frame * @property {number} frame - Gets or sets the current frame index and updates the Texture Cache for display. @@ -1136,7 +1166,7 @@ Object.defineProperty(Phaser.AnimationManager.prototype, 'frameName', { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/AnimationParser.js.html b/docs/AnimationParser.js.html index e262c4fb0..9302149e9 100644 --- a/docs/AnimationParser.js.html +++ b/docs/AnimationParser.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -806,22 +814,22 @@ Phaser.AnimationParser = { uuid = game.rnd.uuid(); frame = frames[i].attributes; - - name = frame.name.nodeValue; - x = parseInt(frame.x.nodeValue, 10); - y = parseInt(frame.y.nodeValue, 10); - width = parseInt(frame.width.nodeValue, 10); - height = parseInt(frame.height.nodeValue, 10); + + name = frame.name.value; + x = parseInt(frame.x.value, 10); + y = parseInt(frame.y.value, 10); + width = parseInt(frame.width.value, 10); + height = parseInt(frame.height.value, 10); frameX = null; frameY = null; if (frame.frameX) { - frameX = Math.abs(parseInt(frame.frameX.nodeValue, 10)); - frameY = Math.abs(parseInt(frame.frameY.nodeValue, 10)); - frameWidth = parseInt(frame.frameWidth.nodeValue, 10); - frameHeight = parseInt(frame.frameHeight.nodeValue, 10); + frameX = Math.abs(parseInt(frame.frameX.value, 10)); + frameY = Math.abs(parseInt(frame.frameY.value, 10)); + frameWidth = parseInt(frame.frameWidth.value, 10); + frameHeight = parseInt(frame.frameHeight.value, 10); } newFrame = data.addFrame(new Phaser.Frame(i, x, y, width, height, name, uuid)); @@ -865,7 +873,7 @@ Phaser.AnimationParser = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/ArcadeParticles.js.html b/docs/ArcadeParticles.js.html new file mode 100644 index 000000000..3f2ac7fcb --- /dev/null +++ b/docs/ArcadeParticles.js.html @@ -0,0 +1,622 @@ + + + + + + Phaser Source: particles/arcade/ArcadeParticles.js + + + + + + + + + + +
    + + +
    + + +
    + +
    + + + +

    Source: particles/arcade/ArcadeParticles.js

    + +
    +
    +
    /**
    +* @author       Richard Davey <rich@photonstorm.com>
    +* @copyright    2014 Photon Storm Ltd.
    +* @license      {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License}
    +*/
    +
    +/**
    +* Arcade Particles is a Particle System integrated with Arcade Physics.
    +*
    +* @class Phaser.Particles.Arcade
    +*/
    +Phaser.Particles.Arcade = {};
    +
    +
    + + + + + +
    + +
    +
    + + + + Phaser Copyright © 2012-2014 Photon Storm Ltd. + +
    + + + Documentation generated by JSDoc 3.3.0-dev + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. + +
    +
    + + +
    +
    + +
    + + + + + + + + + + + + + + + + + + + + diff --git a/docs/ArrayList.js.html b/docs/ArrayList.js.html index c02a8c0e0..fea717739 100644 --- a/docs/ArrayList.js.html +++ b/docs/ArrayList.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -767,7 +775,7 @@ Phaser.ArrayList.prototype.constructor = Phaser.ArrayList; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/AudioSprite.js.html b/docs/AudioSprite.js.html new file mode 100644 index 000000000..a1866bd9a --- /dev/null +++ b/docs/AudioSprite.js.html @@ -0,0 +1,748 @@ + + + + + + Phaser Source: sound/AudioSprite.js + + + + + + + + + + +
    + + +
    + + +
    + +
    + + + +

    Source: sound/AudioSprite.js

    + +
    +
    +
    /**
    + * @author       Jeremy Dowell <jeremy@codevinsky.com>
    + * @author       Richard Davey <rich@photonstorm.com>
    + * @copyright    2014 Photon Storm Ltd.
    + * @license      {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License}
    + */
    +
    +/**
    + * Audio Sprites are a combination of audio files and a JSON configuration.
    + * The JSON follows the format of that created by https://github.com/tonistiigi/audiosprite
    + *
    + * @class Phaser.AudioSprite
    + * @constructor
    + * @param {Phaser.Game} game - Reference to the current game instance.
    + * @param {string} key - Asset key for the sound.
    + */
    +Phaser.AudioSprite = function (game, key) {
    +
    +    /**
    +    * A reference to the currently running Game.
    +    * @property {Phaser.Game} game
    +    */
    +    this.game = game;
    +
    +    /**
    +     * Asset key for the Audio Sprite.
    +     * @property {string} key
    +     */
    +    this.key = key;
    +
    +    /**
    +     * JSON audio atlas object.
    +     * @property {object} config
    +     */
    +    this.config = this.game.cache.getJSON(key + '-audioatlas');
    +
    +    /**
    +     * If a sound is set to auto play, this holds the marker key of it.
    +     * @property {string} autoplayKey
    +     */
    +    this.autoplayKey = null;
    +
    +    /**
    +     * Is a sound set to autoplay or not?
    +     * @property {boolean} autoplay
    +     * @default
    +     */
    +    this.autoplay = false;
    +
    +    /**
    +     * An object containing the Phaser.Sound objects for the Audio Sprite.
    +     * @property {object} sounds
    +     */
    +    this.sounds = {};
    +
    +    for (var k in this.config.spritemap)
    +    {
    +        var marker = this.config.spritemap[k];
    +        var sound = this.game.add.sound(this.key);
    +
    +        if (marker.loop)
    +        {
    +            sound.addMarker(k, marker.start, (marker.end - marker.start), null, true);
    +        }
    +        else
    +        {
    +            sound.addMarker(k, marker.start, (marker.end - marker.start), null, false);
    +        }
    +
    +        this.sounds[k] = sound;
    +    }
    +
    +    if (this.config.autoplay)
    +    {
    +        this.autoplayKey = this.config.autoplay;
    +        this.play(this.autoplayKey);
    +        this.autoplay = this.sounds[this.autoplayKey];
    +    }
    +
    +};
    +
    +Phaser.AudioSprite.prototype = {
    +
    +    /**
    +     * Play a sound with the given name.
    +     * 
    +     * @method Phaser.AudioSprite#play
    +     * @param {string} [marker] - The name of sound to play
    +     * @param {number} [volume=1] - Volume of the sound you want to play. If none is given it will use the volume given to the Sound when it was created (which defaults to 1 if none was specified).
    +     * @return {Phaser.Sound} This sound instance.
    +     */
    +    play: function (marker, volume) {
    +
    +        if (typeof volume === 'undefined') { volume = 1; }
    +
    +        return this.sounds[marker].play(marker, null, volume);
    +
    +    },
    +
    +    /**
    +     * Stop a sound with the given name.
    +     * 
    +     * @method Phaser.AudioSprite#stop
    +     * @param {string} [marker=''] - The name of sound to stop. If none is given it will stop all sounds in the audio sprite.
    +     */
    +    stop: function (marker) {
    +
    +        if (!marker)
    +        {
    +            for (var key in this.sounds)
    +            {
    +                this.sounds[key].stop();
    +            }
    +        }
    +        else
    +        {
    +            this.sounds[marker].stop();
    +        }
    +
    +    },
    +
    +    /**
    +     * Get a sound with the given name.
    +     * 
    +     * @method Phaser.AudioSprite#get
    +     * @param {string} marker - The name of sound to get.
    +     * @return {Phaser.Sound} The sound instance.
    +     */
    +    get: function(marker) {
    +
    +        return this.sounds[marker];
    +
    +    }
    +
    +};
    +
    +Phaser.AudioSprite.prototype.constructor = Phaser.AudioSprite;
    +
    +
    +
    + + + + + +
    + +
    +
    + + + + Phaser Copyright © 2012-2014 Photon Storm Ltd. + +
    + + + Documentation generated by JSDoc 3.3.0-dev + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. + +
    +
    + + +
    +
    + +
    + + + + + + + + + + + + + + + + + + + + diff --git a/docs/BitmapData.js.html b/docs/BitmapData.js.html index 62b3fb288..159293d0e 100644 --- a/docs/BitmapData.js.html +++ b/docs/BitmapData.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,13 +551,11 @@ */ /** -* Creates a new BitmapData object. +* A BitmapData object contains a Canvas element to which you can draw anything you like via normal Canvas context operations. +* A single BitmapData can be used as the texture for one or many Images/Sprites. +* So if you need to dynamically create a Sprite texture then they are a good choice. * * @class Phaser.BitmapData -* -* @classdesc A BitmapData object contains a Canvas element to which you can draw anything you like via normal Canvas context operations. -* A single BitmapData can be used as the texture for one or many Images/Sprites. So if you need to dynamically create a Sprite texture then they are a good choice. -* * @constructor * @param {Phaser.Game} game - A reference to the currently running game. * @param {string} key - Internal Phaser reference key for the render texture. @@ -733,6 +739,12 @@ Phaser.BitmapData = function (game, key, width, height) { */ this._tempB = 0; + /** + * @property {Phaser.Circle} _circle - Internal cache var. + * @private + */ + this._circle = new Phaser.Circle(); + }; Phaser.BitmapData.prototype = { @@ -1429,6 +1441,17 @@ Phaser.BitmapData.prototype = { tx += source.texture.trim.x - source.anchor.x * source.texture.trim.width; ty += source.texture.trim.y - source.anchor.y * source.texture.trim.height; } + + if (source.tint !== 0xFFFFFF) + { + if (source.cachedTint !== source.tint) + { + source.cachedTint = source.tint; + source.tintedTexture = PIXI.CanvasTinter.getTintedTexture(source, source.tint); + } + + this._image = source.tintedTexture; + } } else { @@ -1600,17 +1623,65 @@ Phaser.BitmapData.prototype = { }, + /** + * Sets the shadow properties of this BitmapDatas context which will affect all draw operations made to it. + * You can cancel an existing shadow by calling this method and passing no parameters. + * Note: At the time of writing (October 2014) Chrome still doesn't support shadowBlur used with drawImage. + * + * @method Phaser.BitmapData#shadow + * @param {string} color - The color of the shadow, given in a CSS format, i.e. `#000000` or `rgba(0,0,0,1)`. If `null` or `undefined` the shadow will be reset. + * @param {number} [blur=5] - The amount the shadow will be blurred by. Low values = a crisp shadow, high values = a softer shadow. + * @param {number} [x=10] - The horizontal offset of the shadow in pixels. + * @param {number} [y=10] - The vertical offset of the shadow in pixels. + * @return {Phaser.BitmapData} This BitmapData object for method chaining. + */ + shadow: function (color, blur, x, y) { + + if (typeof color === 'undefined' || color === null) + { + this.context.shadowColor = 'rgba(0,0,0,0)'; + } + else + { + this.context.shadowColor = color; + this.context.shadowBlur = blur || 5; + this.context.shadowOffsetX = x || 10; + this.context.shadowOffsetY = y || 10; + } + + }, + /** * Draws the image onto this BitmapData using an image as an alpha mask. * * @method Phaser.BitmapData#alphaMask * @param {Phaser.Sprite|Phaser.Image|Phaser.Text|Phaser.BitmapData|HTMLImage|HTMLCanvasElement|string} source - The source to copy from. If you give a string it will try and find the Image in the Game.Cache first. This is quite expensive so try to provide the image itself. * @param {Phaser.Sprite|Phaser.Image|Phaser.Text|Phaser.BitmapData|HTMLImage|HTMLCanvasElement|string} [mask] - The object to be used as the mask. If you give a string it will try and find the Image in the Game.Cache first. This is quite expensive so try to provide the image itself. If you don't provide a mask it will use this BitmapData as the mask. + * @param {Phaser.Rectangle} [sourceRect] - A Rectangle where x/y define the coordinates to draw the Source image to and width/height define the size. + * @param {Phaser.Rectangle} [maskRect] - A Rectangle where x/y define the coordinates to draw the Mask image to and width/height define the size. * @return {Phaser.BitmapData} This BitmapData object for method chaining. */ - alphaMask: function (source, mask) { + alphaMask: function (source, mask, sourceRect, maskRect) { - return this.draw(mask).blendSourceAtop().draw(source).blendReset(); + if (typeof maskRect === 'undefined' || maskRect === null) + { + this.draw(mask).blendSourceAtop(); + } + else + { + this.draw(mask, maskRect.x, maskRect.y, maskRect.width, maskRect.height).blendSourceAtop(); + } + + if (typeof sourceRect === 'undefined' || sourceRect === null) + { + this.draw(source).blendReset(); + } + else + { + this.draw(source, sourceRect.x, sourceRect.y, sourceRect.width, sourceRect.height).blendReset(); + } + + return this; }, @@ -1718,6 +1789,54 @@ Phaser.BitmapData.prototype = { }, + /** + * Takes the given Line object and image and renders it to this BitmapData as a repeating texture line. + * + * @method Phaser.BitmapData#textureLine + * @param {Phaser.Line} line - A Phaser.Line object that will be used to plot the start and end of the line. + * @param {string|HTMLImage} image - The key of an image in the Phaser.Cache to use as the texture for this line, or an actual Image. + * @param {string} [repeat='repeat-x'] - The pattern repeat mode to use when drawing the line. Either `repeat`, `repeat-x` or `no-repeat`. + * @return {Phaser.BitmapData} This BitmapData object for method chaining. + */ + textureLine: function (line, image, repeat) { + + if (typeof repeat === 'undefined') { repeat = 'repeat-x'; } + + if (typeof image === 'string') + { + image = this.game.cache.getImage(image); + + if (!image) + { + return; + } + } + + var width = line.length; + + if (repeat === 'no-repeat' && width > image.width) + { + width = image.width; + } + + this.context.fillStyle = this.context.createPattern(image, repeat); + + this._circle = new Phaser.Circle(line.start.x, line.start.y, image.height); + + this._circle.circumferencePoint(line.angle - 1.5707963267948966, false, this._pos); + + this.context.save(); + this.context.translate(this._pos.x, this._pos.y); + this.context.rotate(line.angle); + this.context.fillRect(0, 0, width, image.height); + this.context.restore(); + + this.dirty = true; + + return this; + + }, + /** * If the game is running in WebGL this will push the texture up to the GPU if it's dirty. * This is called automatically if the BitmapData is being used by a Sprite, otherwise you need to remember to call it in your render function. @@ -2148,7 +2267,7 @@ Phaser.BitmapData.prototype.constructor = Phaser.BitmapData; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/BitmapText.js.html b/docs/BitmapText.js.html index be3850cfe..6fc288156 100644 --- a/docs/BitmapText.js.html +++ b/docs/BitmapText.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,17 +551,15 @@ */ /** -* Creates a new BitmapText object. -* -* @class Phaser.BitmapText -* -* @classdesc BitmapText objects work by taking a texture file and an XML file that describes the font layout. +* BitmapText objects work by taking a texture file and an XML file that describes the font layout. * * On Windows you can use the free app BMFont: http://www.angelcode.com/products/bmfont/ * On OS X we recommend Glyph Designer: http://www.71squared.com/en/glyphdesigner * For Web there is the great Littera: http://kvazars.com/littera/ * +* @class Phaser.BitmapText * @constructor +* @extends PIXI.BitmapText * @param {Phaser.Game} game - A reference to the currently running game. * @param {number} x - X position of the new bitmapText object. * @param {number} y - Y position of the new bitmapText object. @@ -1042,7 +1048,7 @@ Object.defineProperty(Phaser.BitmapText.prototype, "destroyPhase", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Body.js.html b/docs/Body.js.html index fbdd9075d..b1fae4d41 100644 --- a/docs/Body.js.html +++ b/docs/Body.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -547,7 +555,6 @@ * the Sprite itself. For example you can set the velocity, acceleration, bounce values etc all on the Body. * * @class Phaser.Physics.Arcade.Body -* @classdesc Arcade Physics Body Constructor * @constructor * @param {Phaser.Sprite} sprite - The Sprite object this physics body belongs to. */ @@ -1388,7 +1395,7 @@ Phaser.Physics.Arcade.Body.prototype.constructor = Phaser.Physics.Arcade.Body; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Body.js_.html b/docs/Body.js_.html index d55d998ca..5ac01ad7c 100644 --- a/docs/Body.js_.html +++ b/docs/Body.js_.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -547,7 +555,6 @@ * the Sprite itself. For example you can set the velocity, bounce values etc all on the Body. * * @class Phaser.Physics.Ninja.Body -* @classdesc Ninja Physics Body Constructor * @constructor * @param {Phaser.Physics.Ninja} system - The physics system this Body belongs to. * @param {Phaser.Sprite} sprite - The Sprite object this physics body belongs to. @@ -1127,7 +1134,7 @@ Phaser.Physics.Ninja.Body.render = function(context, body, color, filled) { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Body.js__.html b/docs/Body.js__.html index defb7be0f..d7dfda250 100644 --- a/docs/Body.js__.html +++ b/docs/Body.js__.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -551,7 +559,6 @@ * Note: When a game object is given a P2 body it has its anchor x/y set to 0.5, so it becomes centered. * * @class Phaser.Physics.P2.Body -* @classdesc Physics Body Constructor * @constructor * @param {Phaser.Game} game - Game reference to the currently running game. * @param {Phaser.Sprite} [sprite] - The Sprite object this physics body belongs to. @@ -2333,7 +2340,7 @@ Object.defineProperty(Phaser.Physics.P2.Body.prototype, "collideWorldBounds", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/BodyDebug.js.html b/docs/BodyDebug.js.html index 71b83f74c..7d0cf08b9 100644 --- a/docs/BodyDebug.js.html +++ b/docs/BodyDebug.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -549,7 +557,6 @@ * So use sparingly and rarely (if ever) in production code. * * @class Phaser.Physics.P2.BodyDebug -* @classdesc Physics Body Debug Constructor * @constructor * @extends Phaser.Group * @param {Phaser.Game} game - Game reference to the currently running game. @@ -984,7 +991,7 @@ Phaser.Utils.extend(Phaser.Physics.P2.BodyDebug.prototype, { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Button.js.html b/docs/Button.js.html index d51ff2719..8a4f61b63 100644 --- a/docs/Button.js.html +++ b/docs/Button.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,9 +551,7 @@ */ /** -* @class Phaser.Button -* -* @classdesc Create a new `Button` object. A Button is a special type of Sprite that is set-up to handle Pointer events automatically. The four states a Button responds to are: +* Create a new `Button` object. A Button is a special type of Sprite that is set-up to handle Pointer events automatically. The four states a Button responds to are: * * * 'Over' - when the Pointer moves over the Button. This is also commonly known as 'hover'. * * 'Out' - when the Pointer that was previously over the Button moves out of it. @@ -554,9 +560,9 @@ * * You can set a unique texture frame and Sound for any of these states. * +* @class Phaser.Button * @constructor * @extends Phaser.Image -* * @param {Phaser.Game} game Current game instance. * @param {number} [x=0] - X position of the Button. * @param {number} [y=0] - Y position of the Button. @@ -1206,7 +1212,7 @@ Phaser.Button.prototype.setState = function (newState) { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Cache.js.html b/docs/Cache.js.html index d1fbcf2f5..b02edf243 100644 --- a/docs/Cache.js.html +++ b/docs/Cache.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,10 +551,10 @@ */ /** -* Phaser.Cache constructor. +* A game only has one instance of a Cache and it is used to store all externally loaded assets such as images, sounds +* and data files as a result of Loader calls. Cached items use string based keys for look-up. * * @class Phaser.Cache -* @classdesc A game only has one instance of a Cache and it is used to store all externally loaded assets such as images, sounds and data files as a result of Loader calls. Cached items use string based keys for look-up. * @constructor * @param {Phaser.Game} game - A reference to the currently running game. */ @@ -558,7 +566,7 @@ Phaser.Cache = function (game) { this.game = game; /** - * @property {object} game - Canvas key-value container. + * @property {object} _canvases - Canvas key-value container. * @private */ this._canvases = {}; @@ -588,11 +596,17 @@ Phaser.Cache = function (game) { this._text = {}; /** - * @property {object} _text - Text key-value container. + * @property {object} _json - JSOIN key-value container. * @private */ this._json = {}; + /** + * @property {object} _xml - XML key-value container. + * @private + */ + this._xml = {}; + /** * @property {object} _physics - Physics data key-value container. * @private @@ -623,6 +637,24 @@ Phaser.Cache = function (game) { */ this._bitmapFont = {}; + /** + * @property {object} _urlMap - Maps URLs to resources. + * @private + */ + this._urlMap = {}; + + /** + * @property {Image} _urlResolver - Used to resolve URLs to the absolute path. + * @private + */ + this._urlResolver = new Image(); + + /** + * @property {string} _urlTemp - Temporary variable to hold a resolved url. + * @private + */ + this._urlTemp = null; + this.addDefaultImage(); this.addMissingImage(); @@ -647,6 +679,7 @@ Phaser.Cache = function (game) { this._cacheMap[Phaser.Cache.BITMAPDATA] = this._bitmapDatas; this._cacheMap[Phaser.Cache.BITMAPFONT] = this._bitmapFont; this._cacheMap[Phaser.Cache.JSON] = this._json; + this._cacheMap[Phaser.Cache.XML] = this._xml; }; @@ -716,6 +749,12 @@ Phaser.Cache.BITMAPFONT = 10; */ Phaser.Cache.JSON = 11; +/** +* @constant +* @type {number} +*/ +Phaser.Cache.XML = 12; + Phaser.Cache.prototype = { /** @@ -751,11 +790,14 @@ Phaser.Cache.prototype = { * @method Phaser.Cache#addBitmapData * @param {string} key - Asset key for this BitmapData. * @param {Phaser.BitmapData} bitmapData - The BitmapData object to be addded to the cache. + * @param {Phaser.FrameData} [frameData] - Optional FrameData set associated with the given BitmapData. * @return {Phaser.BitmapData} The BitmapData object to be addded to the cache. */ - addBitmapData: function (key, bitmapData) { + addBitmapData: function (key, bitmapData, frameData) { - this._bitmapDatas[key] = bitmapData; + bitmapData.key = key; + + this._bitmapDatas[key] = { data: bitmapData, frameData: frameData }; return bitmapData; @@ -798,6 +840,8 @@ Phaser.Cache.prototype = { this._images[key].frameData = Phaser.AnimationParser.spriteSheet(this.game, key, frameWidth, frameHeight, frameMax, margin, spacing); + this._urlMap[this._resolveUrl(url)] = this._images[key]; + }, /** @@ -813,6 +857,8 @@ Phaser.Cache.prototype = { this._tilemaps[key] = { url: url, data: mapData, format: format }; + this._urlMap[this._resolveUrl(url)] = this._tilemaps[key]; + }, /** @@ -845,6 +891,8 @@ Phaser.Cache.prototype = { this._images[key].frameData = Phaser.AnimationParser.XMLData(this.game, atlasData, key); } + this._urlMap[this._resolveUrl(url)] = this._images[key]; + }, /** @@ -869,6 +917,8 @@ Phaser.Cache.prototype = { this._bitmapFont[key] = PIXI.BitmapText.fonts[key]; + this._urlMap[this._resolveUrl(url)] = this._bitmapFont[key]; + }, /** @@ -884,6 +934,8 @@ Phaser.Cache.prototype = { this._physics[key] = { url: url, data: JSONData, format: format }; + this._urlMap[this._resolveUrl(url)] = this._physics[key]; + }, /** @@ -940,20 +992,38 @@ Phaser.Cache.prototype = { this._text[key] = { url: url, data: data }; + this._urlMap[this._resolveUrl(url)] = this._text[key]; + }, /** * Add a new json object into the cache. * * @method Phaser.Cache#addJSON - * @param {string} key - Asset key for the text data. - * @param {string} url - URL of this text data file. - * @param {object} data - Extra text data. + * @param {string} key - Asset key for the json data. + * @param {string} url - URL of this json data file. + * @param {object} data - Extra json data. */ addJSON: function (key, url, data) { this._json[key] = { url: url, data: data }; + this._urlMap[this._resolveUrl(url)] = this._json[key]; + + }, + + /** + * Add a new xml object into the cache. + * + * @method Phaser.Cache#addXML + * @param {string} key - Asset key for the xml file. + * @param {string} url - URL of this xml file. + * @param {object} data - Extra text data. + */ + addXML: function (key, url, data) { + + this._xml[key] = { url: url, data: data }; + }, /** @@ -975,6 +1045,8 @@ Phaser.Cache.prototype = { PIXI.BaseTextureCache[key] = new PIXI.BaseTexture(data); PIXI.TextureCache[key] = new PIXI.Texture(PIXI.BaseTextureCache[key]); + this._urlMap[this._resolveUrl(url)] = this._images[key]; + }, /** @@ -1001,6 +1073,8 @@ Phaser.Cache.prototype = { this._sounds[key] = { url: url, data: data, isDecoding: false, decoded: decoded, webAudio: webAudio, audioTag: audioTag, locked: this.game.sound.touchLocked }; + this._urlMap[this._resolveUrl(url)] = this._sounds[key]; + }, /** @@ -1102,7 +1176,7 @@ Phaser.Cache.prototype = { if (this._bitmapDatas[key]) { - return this._bitmapDatas[key]; + return this._bitmapDatas[key].data; } else { @@ -1175,7 +1249,7 @@ Phaser.Cache.prototype = { } } - + // We did not find the requested fixture console.warn('Phaser.Cache.getPhysicsData: Could not find given fixtureKey: "' + fixtureKey + ' in ' + key + '"'); } @@ -1217,7 +1291,7 @@ Phaser.Cache.prototype = { * Checks if the given key exists in the Canvas Cache. * * @method Phaser.Cache#checkCanvasKey - * @param {string} key - Asset key of the image to check is in the Cache. + * @param {string} key - Asset key of the canvas to check is in the Cache. * @return {boolean} True if the key exists, otherwise false. */ checkCanvasKey: function (key) { @@ -1256,7 +1330,7 @@ Phaser.Cache.prototype = { * Checks if the given key exists in the Sound Cache. * * @method Phaser.Cache#checkSoundKey - * @param {string} key - Asset key of the image to check is in the Cache. + * @param {string} key - Asset key of the sound file to check is in the Cache. * @return {boolean} True if the key exists, otherwise false. */ checkSoundKey: function (key) { @@ -1269,7 +1343,7 @@ Phaser.Cache.prototype = { * Checks if the given key exists in the Text Cache. * * @method Phaser.Cache#checkTextKey - * @param {string} key - Asset key of the image to check is in the Cache. + * @param {string} key - Asset key of the text file to check is in the Cache. * @return {boolean} True if the key exists, otherwise false. */ checkTextKey: function (key) { @@ -1282,7 +1356,7 @@ Phaser.Cache.prototype = { * Checks if the given key exists in the Physics Cache. * * @method Phaser.Cache#checkPhysicsKey - * @param {string} key - Asset key of the image to check is in the Cache. + * @param {string} key - Asset key of the physics data file to check is in the Cache. * @return {boolean} True if the key exists, otherwise false. */ checkPhysicsKey: function (key) { @@ -1295,7 +1369,7 @@ Phaser.Cache.prototype = { * Checks if the given key exists in the Tilemap Cache. * * @method Phaser.Cache#checkTilemapKey - * @param {string} key - Asset key of the image to check is in the Cache. + * @param {string} key - Asset key of the Tilemap to check is in the Cache. * @return {boolean} True if the key exists, otherwise false. */ checkTilemapKey: function (key) { @@ -1308,7 +1382,7 @@ Phaser.Cache.prototype = { * Checks if the given key exists in the Binary Cache. * * @method Phaser.Cache#checkBinaryKey - * @param {string} key - Asset key of the image to check is in the Cache. + * @param {string} key - Asset key of the binary file to check is in the Cache. * @return {boolean} True if the key exists, otherwise false. */ checkBinaryKey: function (key) { @@ -1321,7 +1395,7 @@ Phaser.Cache.prototype = { * Checks if the given key exists in the BitmapData Cache. * * @method Phaser.Cache#checkBitmapDataKey - * @param {string} key - Asset key of the image to check is in the Cache. + * @param {string} key - Asset key of the BitmapData to check is in the Cache. * @return {boolean} True if the key exists, otherwise false. */ checkBitmapDataKey: function (key) { @@ -1334,7 +1408,7 @@ Phaser.Cache.prototype = { * Checks if the given key exists in the BitmapFont Cache. * * @method Phaser.Cache#checkBitmapFontKey - * @param {string} key - Asset key of the image to check is in the Cache. + * @param {string} key - Asset key of the BitmapFont to check is in the Cache. * @return {boolean} True if the key exists, otherwise false. */ checkBitmapFontKey: function (key) { @@ -1347,7 +1421,7 @@ Phaser.Cache.prototype = { * Checks if the given key exists in the JSON Cache. * * @method Phaser.Cache#checkJSONKey - * @param {string} key - Asset key of the image to check is in the Cache. + * @param {string} key - Asset key of the JSON file to check is in the Cache. * @return {boolean} True if the key exists, otherwise false. */ checkJSONKey: function (key) { @@ -1356,6 +1430,37 @@ Phaser.Cache.prototype = { }, + /** + * Checks if the given key exists in the XML Cache. + * + * @method Phaser.Cache#checkXMLKey + * @param {string} key - Asset key of the XML file to check is in the Cache. + * @return {boolean} True if the key exists, otherwise false. + */ + checkXMLKey: function (key) { + + return this.checkKey(Phaser.Cache.XML, key); + + }, + + /** + * Checks if the given URL has been loaded into the Cache. + * + * @method Phaser.Cache#checkUrl + * @param {string} url - The url to check for in the cache. + * @return {boolean} True if the url exists, otherwise false. + */ + checkUrl: function (url) { + + if (this._urlMap[this._resolveUrl(url)]) + { + return true; + } + + return false; + + }, + /** * Get image data by key. * @@ -1402,13 +1507,16 @@ Phaser.Cache.prototype = { * * @method Phaser.Cache#getFrameData * @param {string} key - Asset key of the frame data to retrieve from the Cache. + * @param {string} [map=Phaser.Cache.IMAGE] - The asset map to get the frameData from, for example `Phaser.Cache.IMAGE`. * @return {Phaser.FrameData} The frame data. */ - getFrameData: function (key) { + getFrameData: function (key, map) { - if (this._images[key]) + if (typeof map === 'undefined') { map = Phaser.Cache.IMAGE; } + + if (this._cacheMap[map][key]) { - return this._images[key].frameData; + return this._cacheMap[map][key].frameData; } return null; @@ -1645,6 +1753,26 @@ Phaser.Cache.prototype = { }, + /** + * Get a XML object by key from the cache. + * + * @method Phaser.Cache#getXML + * @param {string} key - Asset key of the XML object to retrieve from the Cache. + * @return {object} The XML object. + */ + getXML: function (key) { + + if (this._xml[key]) + { + return this._xml[key].data; + } + else + { + console.warn('Phaser.Cache.getXML: Invalid key: "' + key + '"'); + } + + }, + /** * Get binary data by key. * @@ -1665,6 +1793,26 @@ Phaser.Cache.prototype = { }, + /** + * Get a cached object by the URL. + * + * @method Phaser.Cache#getUrl + * @param {string} url - The url for the object loaded to get from the cache. + * @return {object} The cached object. + */ + getUrl: function (url) { + + if (this._urlMap[this._resolveUrl(url)]) + { + return this._urlMap[this._resolveUrl(url)]; + } + else + { + console.warn('Phaser.Cache.getUrl: Invalid url: "' + url + '"'); + } + + }, + /** * Gets all keys used by the Cache for the given data type. * @@ -1721,6 +1869,10 @@ Phaser.Cache.prototype = { case Phaser.Cache.JSON: array = this._json; break; + + case Phaser.Cache.XML: + array = this._xml; + break; } if (!array) @@ -1753,13 +1905,23 @@ Phaser.Cache.prototype = { }, /** - * Removes an image from the cache. + * Removes an image from the cache and optionally from the Pixi.BaseTextureCache as well. * * @method Phaser.Cache#removeImage * @param {string} key - Key of the asset you want to remove. + * @param {boolean} [removeFromPixi=true] - Should this image also be removed from the Pixi BaseTextureCache? */ - removeImage: function (key) { + removeImage: function (key, removeFromPixi) { + + if (typeof removeFromPixi === 'undefined') { removeFromPixi = true; } + delete this._images[key]; + + if (removeFromPixi) + { + PIXI.BaseTextureCache[key].destroy(); + } + }, /** @@ -1792,6 +1954,16 @@ Phaser.Cache.prototype = { delete this._json[key]; }, + /** + * Removes a xml object from the cache. + * + * @method Phaser.Cache#removeXML + * @param {string} key - Key of the asset you want to remove. + */ + removeXML: function (key) { + delete this._xml[key]; + }, + /** * Removes a physics data file from the cache. * @@ -1842,6 +2014,24 @@ Phaser.Cache.prototype = { delete this._bitmapFont[key]; }, + /** + * Resolves a url its absolute form. + * + * @method Phaser.Cache#_resolveUrl + * @param {string} url - The url to resolve. + * @private + */ + _resolveUrl: function (url) { + this._urlResolver.src = this.game.load.baseUrl + url; + + this._urlTemp = this._urlResolver.src; + + // ensure no request is actually made + this._urlResolver.src = ''; + + return this._urlTemp; + }, + /** * Clears the cache. Removes every local cache object reference. * @@ -1877,6 +2067,11 @@ Phaser.Cache.prototype = { delete this._json[item]; } + for (var item in this._xml) + { + delete this._xml[item]; + } + for (var item in this._textures) { delete this._textures[item]; @@ -1907,6 +2102,10 @@ Phaser.Cache.prototype = { delete this._bitmapFont[item]; } + this._urlMap = null; + this._urlResolver = null; + this._urlTemp = null; + } }; @@ -1933,7 +2132,7 @@ Phaser.Cache.prototype.constructor = Phaser.Cache; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Camera.js.html b/docs/Camera.js.html index 58962d5f4..4448ee9d6 100644 --- a/docs/Camera.js.html +++ b/docs/Camera.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -647,6 +655,11 @@ Phaser.Camera = function (game, id, x, y, width, height) { */ this.scale = null; + /** + * @property {Phaser.Point} _targetPosition - Internal point used to calculate target position + */ + this._targetPosition = new Phaser.Point(); + }; /** @@ -785,34 +798,41 @@ Phaser.Camera.prototype = { */ updateTarget: function () { + this._targetPosition + .copyFrom(this.target) + .multiply( + this.target.parent ? this.target.parent.worldTransform.a : 1, + this.target.parent ? this.target.parent.worldTransform.d : 1 + ); + if (this.deadzone) { - this._edge = this.target.x - this.view.x; + this._edge = this._targetPosition.x - this.view.x; if (this._edge < this.deadzone.left) { - this.view.x = this.target.x - this.deadzone.left; + this.view.x = this._targetPosition.x - this.deadzone.left; } else if (this._edge > this.deadzone.right) { - this.view.x = this.target.x - this.deadzone.right; + this.view.x = this._targetPosition.x - this.deadzone.right; } - this._edge = this.target.y - this.view.y; + this._edge = this._targetPosition.y - this.view.y; if (this._edge < this.deadzone.top) { - this.view.y = this.target.y - this.deadzone.top; + this.view.y = this._targetPosition.y - this.deadzone.top; } else if (this._edge > this.deadzone.bottom) { - this.view.y = this.target.y - this.deadzone.bottom; + this.view.y = this._targetPosition.y - this.deadzone.bottom; } } else { - this.view.x = this.target.x - this.view.halfWidth; - this.view.y = this.target.y - this.view.halfHeight; + this.view.x = this._targetPosition.x - this.view.halfWidth; + this.view.y = this._targetPosition.y - this.view.halfHeight; } }, @@ -1042,7 +1062,7 @@ Object.defineProperty(Phaser.Camera.prototype, "height", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Canvas.js.html b/docs/Canvas.js.html index 4fcd000eb..df34385a2 100644 --- a/docs/Canvas.js.html +++ b/docs/Canvas.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -872,7 +880,7 @@ Phaser.Canvas = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Circle.js.html b/docs/Circle.js.html index 4b4c924dd..f2575990e 100644 --- a/docs/Circle.js.html +++ b/docs/Circle.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,14 +551,14 @@ */ /** -* Creates a new Circle object with the center coordinate specified by the x and y parameters and the diameter specified by the diameter parameter. If you call this function without parameters, a circle with x, y, diameter and radius properties set to 0 is created. -* @class Circle -* @classdesc Phaser - Circle +* Creates a new Circle object with the center coordinate specified by the x and y parameters and the diameter specified by the diameter parameter. +* If you call this function without parameters, a circle with x, y, diameter and radius properties set to 0 is created. +* +* @class Phaser.Circle * @constructor * @param {number} [x=0] - The x coordinate of the center of the circle. * @param {number} [y=0] - The y coordinate of the center of the circle. * @param {number} [diameter=0] - The diameter of the circle. -* @return {Phaser.Circle} This circle object */ Phaser.Circle = function (x, y, diameter) { @@ -605,7 +613,7 @@ Phaser.Circle.prototype = { * @method Phaser.Circle#setTo * @param {number} x - The x coordinate of the center of the circle. * @param {number} y - The y coordinate of the center of the circle. - * @param {number} diameter - The diameter of the circle in pixels. + * @param {number} diameter - The diameter of the circle. * @return {Circle} This circle object. */ setTo: function (x, y, diameter) { @@ -1093,7 +1101,7 @@ PIXI.Circle = Phaser.Circle; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Circle.js_.html b/docs/Circle.js_.html index 69c4d78ea..3bc62328e 100644 --- a/docs/Circle.js_.html +++ b/docs/Circle.js_.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -548,7 +556,6 @@ * Note: This class could be massively optimised and reduced in size. I leave that challenge up to you. * * @class Phaser.Physics.Ninja.Circle -* @classdesc Arcade Physics Constructor * @constructor * @param {Phaser.Physics.Ninja.Body} body - The body that owns this shape. * @param {number} x - The x coordinate to create this shape at. @@ -3208,7 +3215,7 @@ Phaser.Physics.Ninja.Circle.prototype = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/CollisionGroup.js.html b/docs/CollisionGroup.js.html index 8bc566ba0..97f33ccc5 100644 --- a/docs/CollisionGroup.js.html +++ b/docs/CollisionGroup.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,8 +554,8 @@ * Collision Group * * @class Phaser.Physics.P2.CollisionGroup -* @classdesc Physics Collision Group Constructor * @constructor +* @param {number} bitmask - The CollisionGroup bitmask. */ Phaser.Physics.P2.CollisionGroup = function (bitmask) { @@ -578,7 +586,7 @@ Phaser.Physics.P2.CollisionGroup = function (bitmask) { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Color.js.html b/docs/Color.js.html index 7aadae146..ff1710453 100644 --- a/docs/Color.js.html +++ b/docs/Color.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -977,11 +985,12 @@ Phaser.Color = { */ createColor: function (r, g, b, a, h, s, l, v) { - var out = { r: r || 0, g: g || 0, b: b || 0, a: a || 1, h: h || 0, s: s || 0, l: l || 0, v: v || 0, color: 0 }; + var out = { r: r || 0, g: g || 0, b: b || 0, a: a || 1, h: h || 0, s: s || 0, l: l || 0, v: v || 0, color: 0, color32: 0, rgba: '' }; - out.rgba = 'rgba(' + out.r + ',' + out.g + ',' + out.b + ',' + out.a + ')'; + out.color = Phaser.Color.getColor(out.r, out.g, out.b); + out.color32 = Phaser.Color.getColor32(out.a, out.r, out.g, out.b); - return out; + return Phaser.Color.updateColor(out); }, @@ -995,7 +1004,7 @@ Phaser.Color = { */ updateColor: function (out) { - out.rgba = 'rgba(' + out.r + ',' + out.g + ',' + out.b + ',' + out.a + ')'; + out.rgba = 'rgba(' + out.r.toString() + ',' + out.g.toString() + ',' + out.b.toString() + ',' + out.a.toString() + ')'; return out; @@ -1088,20 +1097,13 @@ Phaser.Color = { * @method Phaser.Color.hexToColor * @static * @param {string} hex - The hex string to convert. Can be in the short-hand format `#03f` or `#0033ff`. - * @param {object} [out] - An object into which 3 properties will be created: r, g and b. If not provided a new object will be created. + * @param {object} [out] - An object into which 3 properties will be created or set: r, g and b. If not provided a new object will be created. * @return {object} An object with the red, green and blue values set in the r, g and b properties. */ hexToColor: function (hex, out) { - if (!out) - { - out = Phaser.Color.createColor(); - } - // Expand shorthand form (e.g. "03F") to full form (e.g. "0033FF") - var shorthandRegex = /^#?([a-f\d])([a-f\d])([a-f\d])$/i; - - hex = hex.replace(shorthandRegex, function(m, r, g, b) { + hex = hex.replace(/^#?([a-f\d])([a-f\d])([a-f\d])$/i, function(m, r, g, b) { return r + r + g + g + b + b; }); @@ -1109,15 +1111,56 @@ Phaser.Color = { if (result) { - out.r = parseInt(result[1], 16); - out.g = parseInt(result[2], 16); - out.b = parseInt(result[3], 16); + var r = parseInt(result[1], 16); + var g = parseInt(result[2], 16); + var b = parseInt(result[3], 16); + + if (!out) + { + out = Phaser.Color.createColor(r, g, b); + } + else + { + out.r = r; + out.g = g; + out.b = b; + } } return out; }, + /** + * Converts a CSS 'web' string into a Phaser Color object. + * + * @method Phaser.Color.webToColor + * @static + * @param {string} web - The web string in the format: 'rgba(r,g,b,a)' + * @param {object} [out] - An object into which 3 properties will be created: r, g and b. If not provided a new object will be created. + * @return {object} An object with the red, green and blue values set in the r, g and b properties. + */ + webToColor: function (web, out) { + + if (!out) + { + out = Phaser.Color.createColor(); + } + + var result = /^rgba?\((\d+),\s*(\d+),\s*(\d+)(?:,\s*(\d+(?:\.\d+)?))?\)$/.exec(web); + + if (result) + { + out.r = parseInt(result[1], 10); + out.g = parseInt(result[2], 10); + out.b = parseInt(result[3], 10); + } + + return out; + + }, + + /** * Return a string containing a hex representation of the given color component. * @@ -1435,7 +1478,7 @@ Phaser.Color = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/ContactMaterial.js.html b/docs/ContactMaterial.js.html index 33056adbf..d3f0593c7 100644 --- a/docs/ContactMaterial.js.html +++ b/docs/ContactMaterial.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,11 +554,10 @@ * Defines a physics material * * @class Phaser.Physics.P2.ContactMaterial -* @classdesc Physics ContactMaterial Constructor * @constructor -* @param {Phaser.Physics.P2.Material} materialA -* @param {Phaser.Physics.P2.Material} materialB -* @param {object} [options] +* @param {Phaser.Physics.P2.Material} materialA - First material participating in the contact material. +* @param {Phaser.Physics.P2.Material} materialB - Second material participating in the contact material. +* @param {object} [options] - Additional configuration options. */ Phaser.Physics.P2.ContactMaterial = function (materialA, materialB, options) { @@ -563,7 +570,7 @@ Phaser.Physics.P2.ContactMaterial = function (materialA, materialB, options) { */ /** - * @property {Phaser.Physics.P2.Material} materialB - First second participating in the contact material. + * @property {Phaser.Physics.P2.Material} materialB - Second material participating in the contact material. */ /** @@ -621,7 +628,7 @@ Phaser.Physics.P2.ContactMaterial.prototype.constructor = Phaser.Physics.P2.Cont Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Debug.js.html b/docs/Debug.js.html index b42826ff5..0fefc359a 100644 --- a/docs/Debug.js.html +++ b/docs/Debug.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1278,18 +1286,22 @@ Phaser.Utils.Debug.prototype = { if (sprite.body) { + this.start(); + if (sprite.body.type === Phaser.Physics.ARCADE) { - this.start(); Phaser.Physics.Arcade.Body.render(this.context, sprite.body, color, filled); - this.stop(); } else if (sprite.body.type === Phaser.Physics.NINJA) { - this.start(); Phaser.Physics.Ninja.Body.render(this.context, sprite.body, color, filled); - this.stop(); } + else if (sprite.body.type === Phaser.Physics.BOX2D) + { + Phaser.Physics.Box2D.renderBody(this.context, sprite.body, color); + } + + this.stop(); } }, @@ -1307,14 +1319,54 @@ Phaser.Utils.Debug.prototype = { if (sprite.body) { + this.start(x, y, color, 210); + if (sprite.body.type === Phaser.Physics.ARCADE) { - this.start(x, y, color, 210); Phaser.Physics.Arcade.Body.renderBodyInfo(this, sprite.body); - this.stop(); } + else if (sprite.body.type === Phaser.Physics.BOX2D) + { + this.game.physics.box2d.renderBodyInfo(this, sprite.body); + } + + this.stop(); } + }, + + /** + * Renders 'debug draw' data for the Box2D world if it exists. + * This uses the standard debug drawing feature of Box2D, so colors will be decided by + * the Box2D engine. + * + * @method Phaser.Utils.Debug#box2dWorld + */ + box2dWorld: function () { + + this.start(); + + this.context.translate(-this.game.camera.view.x, -this.game.camera.view.y, 0); + this.game.physics.box2d.renderDebugDraw(this.context); + + this.stop(); + + }, + + /** + * Renders 'debug draw' data for the given Box2D body. + * This uses the standard debug drawing feature of Box2D, so colors will be decided by the Box2D engine. + * + * @method Phaser.Utils.Debug#box2dBody + * @param {Phaser.Sprite} sprite - The sprite whos body will be rendered. + * @param {string} [color='rgb(0,255,0)'] - color of the debug info to be rendered. (format is css color string). + */ + box2dBody: function (body, color) { + + this.start(); + Phaser.Physics.Box2D.renderBody(this.context, body, color); + this.stop(); + } }; @@ -1341,7 +1393,7 @@ Phaser.Utils.Debug.prototype.constructor = Phaser.Utils.Debug; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Device.js.html b/docs/Device.js.html index 3e2174d48..4e3d49f07 100644 --- a/docs/Device.js.html +++ b/docs/Device.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -548,7 +556,6 @@ * @class Phaser.Device * @constructor */ - Phaser.Device = function (game) { /** @@ -1517,7 +1524,7 @@ Phaser.Device.isAndroidStockBrowser = function() Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/DistanceConstraint.js.html b/docs/DistanceConstraint.js.html index e0018282f..a32328cda 100644 --- a/docs/DistanceConstraint.js.html +++ b/docs/DistanceConstraint.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * A constraint that tries to keep the distance between two bodies constant. * * @class Phaser.Physics.P2.DistanceConstraint -* @classdesc Physics DistanceConstraint Constructor * @constructor * @param {Phaser.Physics.P2} world - A reference to the P2 World. * @param {p2.Body} bodyA - First connected body. @@ -607,7 +614,7 @@ Phaser.Physics.P2.DistanceConstraint.prototype.constructor = Phaser.Physics.P2.D Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Easing.js.html b/docs/Easing.js.html index f04b1eb16..c9b50d402 100644 --- a/docs/Easing.js.html +++ b/docs/Easing.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1122,7 +1130,7 @@ Phaser.Easing.Default = Phaser.Easing.Linear.None; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Ellipse.js.html b/docs/Ellipse.js.html index 2d590fa77..bdce29f6a 100644 --- a/docs/Ellipse.js.html +++ b/docs/Ellipse.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -545,14 +553,13 @@ /** * Creates a Ellipse object. A curve on a plane surrounding two focal points. -* @class Ellipse -* @classdesc Phaser - Ellipse +* +* @class Phaser.Ellipse * @constructor * @param {number} [x=0] - The X coordinate of the upper-left corner of the framing rectangle of this ellipse. * @param {number} [y=0] - The Y coordinate of the upper-left corner of the framing rectangle of this ellipse. * @param {number} [width=0] - The overall width of this ellipse. * @param {number} [height=0] - The overall height of this ellipse. -* @return {Phaser.Ellipse} This Ellipse object */ Phaser.Ellipse = function (x, y, width, height) { @@ -620,7 +627,7 @@ Phaser.Ellipse.prototype = { }, /** - * Copies the x, y and diameter properties from this Circle to any given object. + * Copies the x, y, width and height properties from this Ellipse to any given object. * @method Phaser.Ellipse#copyTo * @param {any} dest - The object to copy to. * @return {Object} This dest object. @@ -853,7 +860,7 @@ PIXI.Ellipse = Phaser.Ellipse; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Emitter.js.html b/docs/Emitter.js.html index 9800d94ef..98036f6a6 100644 --- a/docs/Emitter.js.html +++ b/docs/Emitter.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,12 +551,11 @@ */ /** -* @class Phaser.Particles.Arcade.Emitter -* -* @classdesc Emitter is a lightweight particle emitter that uses Arcade Physics. +* Emitter is a lightweight particle emitter that uses Arcade Physics. * It can be used for one-time explosions or for continuous effects like rain and fire. -* All it really does is launch Particle objects out at set intervals, and fixes their positions and velocities accorindgly. +* All it really does is launch Particle objects out at set intervals, and fixes their positions and velocities accordingly. * +* @class Phaser.Particles.Arcade.Emitter * @constructor * @extends Phaser.Group * @param {Phaser.Game} game - Current game instance. @@ -556,7 +563,6 @@ * @param {number} [y=0] - The y coordinate within the Emitter that the particles are emitted from. * @param {number} [maxParticles=50] - The total number of particles in this emitter. */ - Phaser.Particles.Arcade.Emitter = function (game, x, y, maxParticles) { /** @@ -1393,7 +1399,7 @@ Object.defineProperty(Phaser.Particles.Arcade.Emitter.prototype, "bottom", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Events.js.html b/docs/Events.js.html index 4cad439e5..9567315a1 100644 --- a/docs/Events.js.html +++ b/docs/Events.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,9 +551,7 @@ */ /** -* @class Phaser.Events -* -* @classdesc The Events component is a collection of events fired by the parent game object. +* The Events component is a collection of events fired by the parent game object. * * For example to tell when a Sprite has been added to a new group: * @@ -555,8 +561,8 @@ * * Note that the Input related events only exist if the Sprite has had `inputEnabled` set to `true`. * +* @class Phaser.Events * @constructor -* * @param {Phaser.Sprite} sprite - A reference to Description. */ Phaser.Events = function (sprite) { @@ -718,7 +724,7 @@ Phaser.Events.prototype.constructor = Phaser.Events; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Filter.js.html b/docs/Filter.js.html index 08da89044..eb5a48369 100644 --- a/docs/Filter.js.html +++ b/docs/Filter.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * This is a base Filter template to use for any Phaser filter development. * * @class Phaser.Filter -* @classdesc Phaser - Filter * @constructor * @param {Phaser.Game} game - A reference to the currently running game. * @param {Object} uniforms - Uniform mappings object @@ -722,7 +729,7 @@ Object.defineProperty(Phaser.Filter.prototype, 'height', { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/FixtureList.js.html b/docs/FixtureList.js.html index d76b804b5..ba8ba2152 100644 --- a/docs/FixtureList.js.html +++ b/docs/FixtureList.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -555,7 +563,6 @@ * during runtime (to remove parts, set masks, categories & sensor properties) * * @class Phaser.Physics.P2.FixtureList -* @classdesc Collection for generated P2 fixtures * @constructor * @param {Array} list - A list of fixtures (from Phaser.Physics.P2.Body#addPhaserPolygon) */ @@ -789,7 +796,7 @@ Phaser.Physics.P2.FixtureList.prototype = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/FlexGrid.js.html b/docs/FlexGrid.js.html index 34ce2f514..4ba367758 100644 --- a/docs/FlexGrid.js.html +++ b/docs/FlexGrid.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -572,6 +580,7 @@ Phaser.FlexGrid = function (manager, width, height) { this.width = width; this.height = height; + this.boundsCustom = new Phaser.Rectangle(0, 0, width, height); this.boundsFluid = new Phaser.Rectangle(0, 0, width, height); this.boundsFull = new Phaser.Rectangle(0, 0, width, height); this.boundsNone = new Phaser.Rectangle(0, 0, width, height); @@ -580,6 +589,7 @@ Phaser.FlexGrid = function (manager, width, height) { * @property {Phaser.Point} position - * @readonly */ + this.positionCustom = new Phaser.Point(0, 0); this.positionFluid = new Phaser.Point(0, 0); this.positionFull = new Phaser.Point(0, 0); this.positionNone = new Phaser.Point(0, 0); @@ -588,11 +598,17 @@ Phaser.FlexGrid = function (manager, width, height) { * @property {Phaser.Point} scaleFactor - The scale factor based on the game dimensions vs. the scaled dimensions. * @readonly */ + this.scaleCustom = new Phaser.Point(1, 1); this.scaleFluid = new Phaser.Point(1, 1); this.scaleFluidInversed = new Phaser.Point(1, 1); this.scaleFull = new Phaser.Point(1, 1); this.scaleNone = new Phaser.Point(1, 1); + this.customWidth = 0; + this.customHeight = 0; + this.customOffsetX = 0; + this.customOffsetY = 0; + this.ratioH = width / height; this.ratioV = height / width; @@ -631,6 +647,43 @@ Phaser.FlexGrid.prototype = { // Need ability to create your own layers with custom scaling, etc. + /** + * A custom layer is centered on the game and maintains its aspect ratio as it scales up and down. + * + * @method createCustomLayer + * @param {number} width - Width of this layer in pixels. + * @param {number} height - Height of this layer in pixels. + * @param {array} [children] - An array of children that are used to populate the FlexLayer. + * @return {Phaser.FlexLayer} The Layer object. + */ + createCustomLayer: function (width, height, children, addToWorld) { + + if (typeof addToWorld === 'undefined') { addToWorld = true; } + + this.customWidth = width; + this.customHeight = height; + + this.boundsCustom.width = width; + this.boundsCustom.height = height; + + var layer = new Phaser.FlexLayer(this, this.positionCustom, this.boundsCustom, this.scaleCustom); + + if (addToWorld) + { + this.game.world.add(layer); + } + + this.layers.push(layer); + + if (typeof children !== 'undefined' && typeof children !== null) + { + layer.addMultiple(children); + } + + return layer; + + }, + /** * A fluid layer is centered on the game and maintains its aspect ratio as it scales up and down. * @@ -638,15 +691,20 @@ Phaser.FlexGrid.prototype = { * @param {array} [children] - An array of children that are used to populate the FlexLayer. * @return {Phaser.FlexLayer} The Layer object. */ - createFluidLayer: function (children) { + createFluidLayer: function (children, addToWorld) { + + if (typeof addToWorld === 'undefined') { addToWorld = true; } var layer = new Phaser.FlexLayer(this, this.positionFluid, this.boundsFluid, this.scaleFluid); - this.game.world.add(layer); + if (addToWorld) + { + this.game.world.add(layer); + } this.layers.push(layer); - if (typeof children !== 'undefined') + if (typeof children !== 'undefined' && typeof children !== null) { layer.addMultiple(children); } @@ -710,14 +768,18 @@ Phaser.FlexGrid.prototype = { */ reset: function () { - for (var i = 0; i < this.layers.length; i++) - { - // Remove references to this class - this.layers[i].position = null; - this.layers[i].scale = null; - } + var i = this.layers.length; - this.layers.length = 0; + while (i--) + { + if (!this.layers[i].persist) + { + // Remove references to this class + this.layers[i].position = null; + this.layers[i].scale = null; + this.layers.slice(i, 1); + } + } }, @@ -760,6 +822,24 @@ Phaser.FlexGrid.prototype = { this.positionFluid.set(this.boundsFluid.x, this.boundsFluid.y); this.positionNone.set(this.boundsNone.x, this.boundsNone.y); + // Custom Layer + + /* + if (this.customWidth > 0) + { + var customMultiplier = Math.min((this.manager.height / this.customHeight), (this.manager.width / this.customWidth)); + + this.boundsCustom.width = Math.round(this.customWidth * customMultiplier); + this.boundsCustom.height = Math.round(this.customHeight * customMultiplier); + + this.boundsCustom.centerOn(this.manager.bounds.centerX, this.manager.bounds.centerY); + + this.scaleCustom.set(this.boundsCustom.width / this.width, this.boundsCustom.height / this.height); + + this.positionCustom.set(this.boundsCustom.x, this.boundsCustom.y); + } + */ + }, /** @@ -774,14 +854,17 @@ Phaser.FlexGrid.prototype = { // this.layers[i].debug(); // } - this.game.debug.text(this.boundsFull.width + ' x ' + this.boundsFull.height, this.boundsFull.x + 4, this.boundsFull.y + 16); - this.game.debug.geom(this.boundsFull, 'rgba(0,0,255,0.9', false); + // this.game.debug.text(this.boundsFull.width + ' x ' + this.boundsFull.height, this.boundsFull.x + 4, this.boundsFull.y + 16); + // this.game.debug.geom(this.boundsFull, 'rgba(0,0,255,0.9', false); this.game.debug.text(this.boundsFluid.width + ' x ' + this.boundsFluid.height, this.boundsFluid.x + 4, this.boundsFluid.y + 16); this.game.debug.geom(this.boundsFluid, 'rgba(255,0,0,0.9', false); - this.game.debug.text(this.boundsNone.width + ' x ' + this.boundsNone.height, this.boundsNone.x + 4, this.boundsNone.y + 16); - this.game.debug.geom(this.boundsNone, 'rgba(0,255,0,0.9', false); + // this.game.debug.text(this.boundsNone.width + ' x ' + this.boundsNone.height, this.boundsNone.x + 4, this.boundsNone.y + 16); + // this.game.debug.geom(this.boundsNone, 'rgba(0,255,0,0.9', false); + + // this.game.debug.text(this.boundsCustom.width + ' x ' + this.boundsCustom.height, this.boundsCustom.x + 4, this.boundsCustom.y + 16); + // this.game.debug.geom(this.boundsCustom, 'rgba(255,255,0,0.9', false); } @@ -809,7 +892,7 @@ Phaser.FlexGrid.prototype.constructor = Phaser.FlexGrid; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/FlexLayer.js.html b/docs/FlexLayer.js.html index c7338c4a1..45e18b05c 100644 --- a/docs/FlexLayer.js.html +++ b/docs/FlexLayer.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -564,12 +572,19 @@ Phaser.FlexLayer = function (manager, position, bounds, scale) { /** * @property {Phaser.ScaleManager} scale - A reference to the ScaleManager. */ - this.manager = manager; + this.manager = manager.manager; /** * @property {Phaser.FlexGrid} grid - A reference to the FlexGrid that owns this layer. */ - this.grid = manager.grid; + this.grid = manager; + + /** + * Should the FlexLayer remain through a State swap? + * + * @type {boolean} + */ + this.persist = false; // Bound to the grid this.position = position; @@ -624,7 +639,7 @@ Phaser.FlexLayer.prototype.debug = function () { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Frame.js.html b/docs/Frame.js.html index 267278844..7ecf38856 100644 --- a/docs/Frame.js.html +++ b/docs/Frame.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -772,7 +780,7 @@ Phaser.Frame.prototype.constructor = Phaser.Frame; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:44 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/FrameData.js.html b/docs/FrameData.js.html index fb74fa4b9..8d1cf812a 100644 --- a/docs/FrameData.js.html +++ b/docs/FrameData.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -821,7 +829,7 @@ Object.defineProperty(Phaser.FrameData.prototype, "total", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:44 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Game.js.html b/docs/Game.js.html index 45010ad97..9751a2a46 100644 --- a/docs/Game.js.html +++ b/docs/Game.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,14 +551,12 @@ */ /** -* Game constructor -* -* Instantiate a new <code>Phaser.Game</code> object. -* @class Phaser.Game -* @classdesc This is where the magic happens. The Game object is the heart of your game, +* This is where the magic happens. The Game object is the heart of your game, * providing quick access to common functions and handling the boot process. * "Hell, there are no rules here - we're trying to accomplish something." * Thomas A. Edison +* +* @class Phaser.Game * @constructor * @param {number|string} [width=800] - The width of your game in game pixels. If given as a string the value must be between 0 and 100 and will be used as the percentage width of the parent container, or the browser window if no parent is given. * @param {number|string} [height=600] - The height of your game in game pixels. If given as a string the value must be between 0 and 100 and will be used as the percentage height of the parent container, or the browser window if no parent is given. @@ -558,7 +564,7 @@ * @param {string|HTMLElement} [parent=''] - The DOM element into which this games canvas will be injected. Either a DOM ID (string) or the element itself. * @param {object} [state=null] - The default state object. A object consisting of Phaser.State functions (preload, create, update, render) or null. * @param {boolean} [transparent=false] - Use a transparent canvas background or not. -* @param {boolean} [antialias=true] - Draw all image textures anti-aliased or not. The default is for smooth textures, but disable if your game features pixel art. +* @param {boolean} [antialias=true] - Draw all image textures anti-aliased or not. The default is for smooth textures, but disable if your game features pixel art. * @param {object} [physicsConfig=null] - A physics configuration object to pass to the Physics world on creation. */ Phaser.Game = function (width, height, renderer, parent, state, transparent, antialias, physicsConfig) { @@ -1468,7 +1474,7 @@ Object.defineProperty(Phaser.Game.prototype, "paused", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/GameObjectCreator.js.html b/docs/GameObjectCreator.js.html index 9138f496b..97e883501 100644 --- a/docs/GameObjectCreator.js.html +++ b/docs/GameObjectCreator.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -663,6 +671,19 @@ Phaser.GameObjectCreator.prototype = { }, + /** + * Creates a new AudioSprite object. + * + * @method Phaser.GameObjectCreator#audioSprite + * @param {string} key - The Game.cache key of the sound that this object will use. + * @return {Phaser.AudioSprite} The newly created AudioSprite object. + */ + audioSprite: function (key) { + + return this.game.sound.addSprite(key); + + }, + /** * Creates a new Sound object. * @@ -942,7 +963,7 @@ Phaser.GameObjectCreator.prototype.constructor = Phaser.GameObjectCreator; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/GameObjectFactory.js.html b/docs/GameObjectFactory.js.html index 377471843..a87a27689 100644 --- a/docs/GameObjectFactory.js.html +++ b/docs/GameObjectFactory.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -714,6 +722,19 @@ Phaser.GameObjectFactory.prototype = { sound: function (key, volume, loop, connect) { return this.game.sound.add(key, volume, loop, connect); + + }, + + /** + * Creates a new AudioSprite object. + * + * @method Phaser.GameObjectFactory#audioSprite + * @param {string} key - The Game.cache key of the sound that this object will use. + * @return {Phaser.AudioSprite} The newly created AudioSprite object. + */ + audioSprite: function (key) { + + return this.game.sound.addSprite(key); }, @@ -1016,7 +1037,7 @@ Phaser.GameObjectFactory.prototype.constructor = Phaser.GameObjectFactory; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Gamepad.js.html b/docs/Gamepad.js.html index b7981207f..984bc7d13 100644 --- a/docs/Gamepad.js.html +++ b/docs/Gamepad.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1215,7 +1223,7 @@ Phaser.Gamepad.PS3XC_STICK_RIGHT_Y = 3; // analog stick, range -1..1 Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/GamepadButton.js.html b/docs/GamepadButton.js.html index f178f67b2..9fd5991e6 100644 --- a/docs/GamepadButton.js.html +++ b/docs/GamepadButton.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -544,8 +552,9 @@ */ /** +* If you need more fine-grained control over the handling of specific buttons you can create and use Phaser.GamepadButton objects. +* * @class Phaser.GamepadButton -* @classdesc If you need more fine-grained control over the handling of specific buttons you can create and use Phaser.GamepadButton objects. * @constructor * @param {Phaser.SinglePad} pad - A reference to the gamepad that owns this button. * @param {number} buttonCode - The button code this GamepadButton is responsible for. @@ -768,7 +777,7 @@ Phaser.GamepadButton.prototype.constructor = Phaser.GamepadButton; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/GearConstraint.js.html b/docs/GearConstraint.js.html index 4ac765781..f7e9bb476 100644 --- a/docs/GearConstraint.js.html +++ b/docs/GearConstraint.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * Connects two bodies at given offset points, letting them rotate relative to each other around this point. * * @class Phaser.Physics.P2.GearConstraint -* @classdesc Physics GearConstraint Constructor * @constructor * @param {Phaser.Physics.P2} world - A reference to the P2 World. * @param {p2.Body} bodyA - First connected body. @@ -598,7 +605,7 @@ Phaser.Physics.P2.GearConstraint.prototype.constructor = Phaser.Physics.P2.GearC Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Graphics.js.html b/docs/Graphics.js.html index 165500e15..7a0c2a65a 100644 --- a/docs/Graphics.js.html +++ b/docs/Graphics.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -547,7 +555,7 @@ * * @class Phaser.Graphics * @constructor -* +* @extends PIXI.Graphics * @param {Phaser.Game} game Current game instance. * @param {number} x - X position of the new graphics object. * @param {number} y - Y position of the new graphics object. @@ -943,7 +951,7 @@ Object.defineProperty(Phaser.Graphics.prototype, "destroyPhase", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Group.js.html b/docs/Group.js.html index e22096b36..80207a0e7 100644 --- a/docs/Group.js.html +++ b/docs/Group.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,9 +551,10 @@ */ /** -* Phaser Group constructor. +* A Group is a container for display objects that allows for fast pooling and object recycling. +* Groups can be nested within other Groups and have their own local transforms. +* * @class Phaser.Group -* @classdesc A Group is a container for display objects that allows for fast pooling and object recycling. Groups can be nested within other Groups and have their own local transforms. * @constructor * @param {Phaser.Game} game - A reference to the currently running game. * @param {Phaser.Group|Phaser.Sprite|null} parent - The parent Group, DisplayObject or DisplayObjectContainer that this Group will be added to. If `undefined` it will use game.world. If null it won't be added to anything. @@ -612,6 +621,12 @@ Phaser.Group = function (game, parent, name, addToStage, enableBody, physicsBody */ this.exists = true; + /** + * @property {boolean} ignoreDestroy - A Group with `ignoreDestroy` set to `true` ignores all calls to its `destroy` method. + * @default + */ + this.ignoreDestroy = false; + /** * The type of objects that will be created when you use Group.create or Group.createMultiple. Defaults to Phaser.Sprite. * When a new object is created it is passed the following parameters to its constructor: game, x, y, key, frame. @@ -1326,7 +1341,7 @@ Phaser.Group.prototype.checkProperty = function (child, key, value, force) { { return false; } - + if (Phaser.Utils.getProperty(child, key) !== value) { return false; @@ -1736,6 +1751,36 @@ Phaser.Group.prototype.postUpdate = function () { }; + +/** +* Allows you to obtain a Phaser.ArrayList of children that return true for the given predicate +* For example: +* var healthyList = Group.filter(function(child, index, children) { +* return child.health > 10 ? true : false; +* }, true); +* healthyList.callAll('attack'); +* Note: Currently this will skip any children which are Groups themselves. +* @method Phaser.Group#filter +* @param {function} predicate - The function that each child will be evaluated against. Each child of the Group will be passed to it as its first parameter, the index as the second, and the entire child array as the third +* @param {boolean} [checkExists=false] - If set only children with exists=true will be passed to the callback, otherwise all children will be passed. +* @return {Phaser.ArrayList} Returns an array list containing all the children that the predicate returned true for +*/ +Phaser.Group.prototype.filter = function(predicate, checkExists) { + var index = -1, + length = this.children.length, + result = new Phaser.ArrayList(); + + while(++index < length) { + var child = this.children[index]; + if(!checkExists || (checkExists && child.exists)) { + if(predicate(child, index, this.children)) { + result.add(child); + } + } + } + return result; +}; + /** * Allows you to call your own function on each member of this Group. You must pass the callback and context in which it will run. * After the checkExists parameter you can add as many parameters as you like, which will all be passed to the callback along with the child. @@ -2250,7 +2295,7 @@ Phaser.Group.prototype.removeBetween = function (startIndex, endIndex, destroy, */ Phaser.Group.prototype.destroy = function (destroyChildren, soft) { - if (this.game === null) { return; } + if (this.game === null || this.ignoreDestroy) { return; } if (typeof destroyChildren === 'undefined') { destroyChildren = true; } if (typeof soft === 'undefined') { soft = false; } @@ -2407,7 +2452,7 @@ Object.defineProperty(Phaser.Group.prototype, "fixedToCamera", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Image.js.html b/docs/Image.js.html index 70fd3a0e4..86a401bf6 100644 --- a/docs/Image.js.html +++ b/docs/Image.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,11 +551,11 @@ */ /** -* @class Phaser.Image -* -* @classdesc 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. +* 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. * +* @class Phaser.Image +* @extends PIXI.Sprite * @constructor * @param {Phaser.Game} game - A reference to the currently running game. * @param {number} x - The x coordinate of the Image. The coordinate is relative to any parent container this Image may be in. @@ -799,7 +807,13 @@ Phaser.Image.prototype.loadTexture = function (key, frame) { } else if (key instanceof Phaser.BitmapData) { + // This works from a reference, which probably isn't what we need here this.setTexture(key.texture); + + if (this.game.cache.getFrameData(key.key, Phaser.Cache.BITMAPDATA)) + { + setFrame = !this.animations.loadFrameData(this.game.cache.getFrameData(key.key, Phaser.Cache.BITMAPDATA), frame); + } } else if (key instanceof PIXI.Texture) { @@ -879,6 +893,10 @@ Phaser.Image.prototype.setFrame = function(frame) { this.texture.frame.width = frame.sourceSizeW; this.texture.frame.height = frame.sourceSizeH; } + else if (!frame.trimmed && this.texture.trim) + { + this.texture.trim = null; + } if (this.cropRect) { @@ -1482,7 +1500,7 @@ Object.defineProperty(Phaser.Image.prototype, "destroyPhase", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Input.js.html b/docs/Input.js.html index fad1bd07b..ee37754c1 100644 --- a/docs/Input.js.html +++ b/docs/Input.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1529,7 +1537,7 @@ Object.defineProperty(Phaser.Input.prototype, "worldY", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/InputHandler.js.html b/docs/InputHandler.js.html index 3b02c440a..575cfb54a 100644 --- a/docs/InputHandler.js.html +++ b/docs/InputHandler.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -544,6 +552,7 @@ /** * The Input Handler is bound to a specific Sprite and is responsible for managing all Input events on that Sprite. +* * @class Phaser.InputHandler * @constructor * @param {Phaser.Sprite} sprite - The Sprite object to which this Input Handler belongs. @@ -709,6 +718,11 @@ Phaser.InputHandler = function (sprite) { */ this.consumePointerEvent = false; + /** + * @property {boolean} scaleLayer - EXPERIMENTAL: Please do not use this property unless you know what it does. Likely to change in the future. + */ + this.scaleLayer = false; + /** * @property {boolean} _dragPhase - Internal cache var. * @private @@ -1546,16 +1560,19 @@ Phaser.InputHandler.prototype = { return false; } + var px = this.globalToLocalX(pointer.x) + this._dragPoint.x + this.dragOffset.x; + var py = this.globalToLocalY(pointer.y) + this._dragPoint.y + this.dragOffset.y; + if (this.sprite.fixedToCamera) { if (this.allowHorizontalDrag) { - this.sprite.cameraOffset.x = pointer.x + this._dragPoint.x + this.dragOffset.x; + this.sprite.cameraOffset.x = px; } if (this.allowVerticalDrag) { - this.sprite.cameraOffset.y = pointer.y + this._dragPoint.y + this.dragOffset.y; + this.sprite.cameraOffset.y = py; } if (this.boundsRect) @@ -1578,12 +1595,12 @@ Phaser.InputHandler.prototype = { { if (this.allowHorizontalDrag) { - this.sprite.x = pointer.x + this._dragPoint.x + this.dragOffset.x; + this.sprite.x = px; } if (this.allowVerticalDrag) { - this.sprite.y = pointer.y + this._dragPoint.y + this.dragOffset.y; + this.sprite.y = py; } if (this.boundsRect) @@ -1797,14 +1814,12 @@ Phaser.InputHandler.prototype = { if (this.dragFromCenter) { var bounds = this.sprite.getBounds(); - this.sprite.x = pointer.x + (this.sprite.x - bounds.centerX); - this.sprite.y = pointer.y + (this.sprite.y - bounds.centerY); - this._dragPoint.setTo(this.sprite.x - pointer.x, this.sprite.y - pointer.y); - } - else - { - this._dragPoint.setTo(this.sprite.x - pointer.x, this.sprite.y - pointer.y); + + this.sprite.x = this.globalToLocalX(pointer.x) + (this.sprite.x - bounds.centerX); + this.sprite.y = this.globalToLocalY(pointer.y) + (this.sprite.y - bounds.centerY); } + + this._dragPoint.setTo(this.sprite.x - this.globalToLocalX(pointer.x), this.sprite.y - this.globalToLocalY(pointer.y)); } this.updateDrag(pointer); @@ -1819,6 +1834,40 @@ Phaser.InputHandler.prototype = { }, + /** + * Warning: EXPERIMENTAL + * @method Phaser.InputHandler#globalToLocalX + * @param {number} x + */ + globalToLocalX: function (x) { + + if (this.scaleLayer) + { + x -= this.game.scale.grid.boundsFluid.x; + x *= this.game.scale.grid.scaleFluidInversed.x; + } + + return x; + + }, + + /** + * Warning: EXPERIMENTAL + * @method Phaser.InputHandler#globalToLocalY + * @param {number} y + */ + globalToLocalY: function (y) { + + if (this.scaleLayer) + { + y -= this.game.scale.grid.boundsFluid.y; + y *= this.game.scale.grid.scaleFluidInversed.y; + } + + return y; + + }, + /** * Called by Pointer when drag is stopped on this Sprite. Should not usually be called directly. * @method Phaser.InputHandler#stopDrag @@ -2030,7 +2079,7 @@ Phaser.InputHandler.prototype.constructor = Phaser.InputHandler; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/InversePointProxy.js.html b/docs/InversePointProxy.js.html index d14f91803..0f69d622a 100644 --- a/docs/InversePointProxy.js.html +++ b/docs/InversePointProxy.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * A InversePointProxy is an internal class that allows for direct getter/setter style property access to Arrays and TypedArrays but inverses the values on set. * * @class Phaser.Physics.P2.InversePointProxy -* @classdesc InversePointProxy * @constructor * @param {Phaser.Physics.P2} world - A reference to the P2 World. * @param {any} destination - The object to bind to. @@ -660,7 +667,7 @@ Object.defineProperty(Phaser.Physics.P2.InversePointProxy.prototype, "my", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Key.js.html b/docs/Key.js.html index 5e2c8af92..6d7825f86 100644 --- a/docs/Key.js.html +++ b/docs/Key.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,8 +551,9 @@ */ /** +* If you need more fine-grained control over the handling of specific keys you can create and use Phaser.Key objects. +* * @class Phaser.Key -* @classdesc If you need more fine-grained control over the handling of specific keys you can create and use Phaser.Key objects. * @constructor * @param {Phaser.Game} game - Current game instance. * @param {number} keycode - The key code this Key is responsible for. @@ -805,7 +814,7 @@ Phaser.Key.prototype.constructor = Phaser.Key; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Keyboard.js.html b/docs/Keyboard.js.html index bbddaa3d1..9b757e05f 100644 --- a/docs/Keyboard.js.html +++ b/docs/Keyboard.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1194,6 +1202,8 @@ Phaser.Keyboard.INSERT = 45; Phaser.Keyboard.DELETE = 46; Phaser.Keyboard.HELP = 47; Phaser.Keyboard.NUM_LOCK = 144; +Phaser.Keyboard.PLUS = 43; +Phaser.Keyboard.MINUS = 45; @@ -1215,7 +1225,7 @@ Phaser.Keyboard.NUM_LOCK = 144; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Line.js.html b/docs/Line.js.html index 936078ae2..abe7883c3 100644 --- a/docs/Line.js.html +++ b/docs/Line.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -544,14 +552,13 @@ /** * Creates a new Line object with a start and an end point. -* @class Line -* @classdesc Phaser - Line +* +* @class Phaser.Line * @constructor * @param {number} [x1=0] - The x coordinate of the start of the line. * @param {number} [y1=0] - The y coordinate of the start of the line. * @param {number} [x2=0] - The x coordinate of the end of the line. * @param {number} [y2=0] - The y coordinate of the end of the line. -* @return {Phaser.Line} This line object */ Phaser.Line = function (x1, y1, x2, y2) { @@ -609,10 +616,8 @@ Phaser.Line.prototype = { { return this.setTo(startSprite.center.x, startSprite.center.y, endSprite.center.x, endSprite.center.y); } - else - { - return this.setTo(startSprite.x, startSprite.y, endSprite.x, endSprite.y); - } + + return this.setTo(startSprite.x, startSprite.y, endSprite.x, endSprite.y); }, @@ -993,7 +998,7 @@ Phaser.Line.intersects = function (a, b, asSegment, result) { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/LinkedList.js.html b/docs/LinkedList.js.html index bbd6c614a..bbdf033fb 100644 --- a/docs/LinkedList.js.html +++ b/docs/LinkedList.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -735,7 +743,7 @@ Phaser.LinkedList.prototype.constructor = Phaser.LinkedList; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Loader.js.html b/docs/Loader.js.html index e154e7856..939afed4b 100644 --- a/docs/Loader.js.html +++ b/docs/Loader.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -544,12 +552,10 @@ */ /** -* Phaser loader constructor. * The Loader handles loading all external content such as Images, Sounds, Texture Atlases and data files. * It uses a combination of Image() loading and xhr and provides progress and completion callbacks. +* * @class Phaser.Loader -* @classdesc The Loader handles loading all external content such as Images, Sounds, Texture Atlases and data files. -* It uses a combination of Image() loading and xhr and provides progress and completion callbacks. * @constructor * @param {Phaser.Game} game - A reference to the currently running game. */ @@ -588,7 +594,7 @@ Phaser.Loader = function (game) { * You can optionally link a sprite to the preloader. * If you do so the Sprites width or height will be cropped based on the percentage loaded. * This property is an object containing: sprite, rect, direction, width and height - * + * * @property {object} preloadSprite */ this.preloadSprite = null; @@ -634,10 +640,10 @@ Phaser.Loader = function (game) { this.onLoadComplete = new Phaser.Signal(); /** - * @property {Phaser.Signal} onPackComplete - This event is dispatched when an asset pack has either loaded or failed. + * @property {Phaser.Signal} onPackComplete - This event is dispatched when an asset pack has either loaded or failed. */ this.onPackComplete = new Phaser.Signal(); - + /** * @property {boolean} useXDomainRequest - If true and if the browser supports XDomainRequest, it will be used in preference for xhr when loading json files. It is enabled automatically if the browser is IE9, but you can disable it as required. */ @@ -755,7 +761,7 @@ Phaser.Loader.prototype = { /** * Check whether asset exists with a specific key. * Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey - * + * * @method Phaser.Loader#checkKeyExists * @param {string} type - The type asset you want to check. * @param {string} key - Key of the asset you want to check. @@ -1039,6 +1045,32 @@ Phaser.Loader.prototype = { }, + /** + * Add an XML file to the Loader. + * + * @method Phaser.Loader#xml + * @param {string} key - Unique asset key of the xml file. + * @param {string} url - URL of the xml file. + * @param {boolean} [overwrite=false] - If an unloaded file with a matching key already exists in the queue, this entry will overwrite it. + * @return {Phaser.Loader} This Loader instance. + */ + xml: function (key, url, overwrite) { + + if (typeof overwrite === "undefined") { overwrite = false; } + + if (overwrite) + { + this.replaceInFileList('xml', key, url); + } + else + { + this.addToFileList('xml', key, url); + } + + return this; + + }, + /** * Add a JavaScript file to the Loader. Once loaded the JavaScript file will be automatically turned into a script tag (and executed), so be careful what you load! * You can also specify a callback. This will be executed as soon as the script tag has been created. @@ -1128,6 +1160,26 @@ Phaser.Loader.prototype = { }, + /** + * Add a new audiosprite file to the loader. Audio Sprites are a combination of audio files and a JSON configuration. + * The JSON follows the format of that created by https://github.com/tonistiigi/audiosprite + * + * @method Phaser.Loader#audiosprite + * @param {string} key - Unique asset key of the audio file. + * @param {Array|string} urls - An array containing the URLs of the audio files, i.e.: [ 'audiosprite.mp3', 'audiosprite.ogg', 'audiosprite.m4a' ] or a single string containing just one URL. + * @param {string} atlasURL - The URL of the audiosprite configuration json. + * @return {Phaser.Loader} This Loader instance. + */ + audiosprite: function(key, urls, atlasURL) { + + this.audio(key, urls); + + this.json(key + '-audioatlas', atlasURL); + + return this; + + }, + /** * Add a new tilemap loading request. * @@ -1514,7 +1566,7 @@ Phaser.Loader.prototype = { console.warn('Phaser.Loader loadPackList invalid index ' + this._packIndex); return; } - + var pack = this._packList[this._packIndex]; if (pack.data !== null) @@ -1582,6 +1634,10 @@ Phaser.Loader.prototype = { this.json(file.key, file.url, file.overwrite); break; + case "xml": + this.xml(file.key, file.url, file.overwrite); + break; + case "script": this.script(file.key, file.url, file.callback, pack.callbackContext); break; @@ -1689,11 +1745,11 @@ Phaser.Loader.prototype = { console.warn('Phaser.Loader loadFile invalid index ' + this._fileIndex); return; } - + var file = this._fileList[this._fileIndex]; var _this = this; - this.onFileStart.dispatch(this.progress, file.key); + this.onFileStart.dispatch(this.progress, file.key, file.url); // Image or Data? switch (file.type) @@ -1747,7 +1803,7 @@ Phaser.Loader.prototype = { }; file.data.preload = 'auto'; file.data.src = this.baseURL + file.url; - file.data.addEventListener('canplaythrough', Phaser.GAMES[this.game.id].load.fileComplete(this._fileIndex), false); + file.data.addEventListener('canplaythrough', function () { Phaser.GAMES[_this.game.id].load.fileComplete(_this._fileIndex); }, false); file.data.load(); } } @@ -1773,7 +1829,7 @@ Phaser.Loader.prototype = { this._ajax.onerror = function () { return _this.dataLoadError(_this._fileIndex); }; - + this._ajax.ontimeout = function () { return _this.dataLoadError(_this._fileIndex); }; @@ -1786,7 +1842,7 @@ Phaser.Loader.prototype = { this._ajax.open('GET', this.baseURL + file.url, true); - // Note: The xdr.send() call is wrapped in a timeout to prevent an issue with the interface where some requests are lost + // Note: The xdr.send() call is wrapped in a timeout to prevent an issue with the interface where some requests are lost // if multiple XDomainRequests are being sent at the same time. setTimeout(function () { this._ajax.send(); @@ -1799,6 +1855,11 @@ Phaser.Loader.prototype = { break; + case 'xml': + + this.xhrLoad(this._fileIndex, this.baseURL + file.url, 'text', 'xmlLoadComplete', 'dataLoadError'); + break; + case 'tilemap': if (file.format === Phaser.Tilemap.TILED_JSON) @@ -1830,7 +1891,7 @@ Phaser.Loader.prototype = { /** * Starts the xhr loader. - * + * * @method Phaser.Loader#xhrLoad * @private * @param {number} index - The index of the file to load from the file list. @@ -1860,7 +1921,7 @@ Phaser.Loader.prototype = { /** * Private method ONLY used by loader. - * + * * @method Phaser.Loader#getAudioURL * @private * @param {array|string} urls - Either an array of audio file URLs or a string containing a single URL path. @@ -2149,6 +2210,12 @@ Phaser.Loader.prototype = { */ xmlLoadComplete: function (index) { + if (this._xhr.responseType !== '' && this._xhr.responseType !== 'text') + { + console.warn('Invalid XML Response Type', this._fileList[index]); + console.warn(this._xhr); + } + var data = this._xhr.responseText; var xml; @@ -2179,14 +2246,18 @@ Phaser.Loader.prototype = { var file = this._fileList[index]; file.loaded = true; - if (file.type == 'bitmapfont') + if (file.type === 'bitmapfont') { this.game.cache.addBitmapFont(file.key, file.url, file.data, xml, file.xSpacing, file.ySpacing); } - else if (file.type == 'textureatlas') + else if (file.type === 'textureatlas') { this.game.cache.addTextureAtlas(file.key, file.url, file.data, xml, file.format); } + else if (file.type === 'xml') + { + this.game.cache.addXML(file.key, file.url, xml); + } this.nextFile(index, true); @@ -2355,7 +2426,7 @@ Phaser.Loader.prototype.constructor = Phaser.Loader; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/LoaderParser.js.html b/docs/LoaderParser.js.html index 73e2dc8d5..ef07e13cc 100644 --- a/docs/LoaderParser.js.html +++ b/docs/LoaderParser.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -629,7 +637,7 @@ Phaser.LoaderParser = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/LockConstraint.js.html b/docs/LockConstraint.js.html index a3fee129c..04ffaf13e 100644 --- a/docs/LockConstraint.js.html +++ b/docs/LockConstraint.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * Locks the relative position between two bodies. * * @class Phaser.Physics.P2.LockConstraint -* @classdesc Physics LockConstraint Constructor * @constructor * @param {Phaser.Physics.P2} world - A reference to the P2 World. * @param {p2.Body} bodyA - First connected body. @@ -602,7 +609,7 @@ Phaser.Physics.P2.LockConstraint.prototype.constructor = Phaser.Physics.P2.LockC Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/MSPointer.js.html b/docs/MSPointer.js.html index 7ba2abf18..251f59789 100644 --- a/docs/MSPointer.js.html +++ b/docs/MSPointer.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,12 +551,11 @@ */ /** -* Phaser - MSPointer constructor. -* -* @class Phaser.MSPointer -* @classdesc The MSPointer class handles touch interactions with the game and the resulting Pointer objects. +* The MSPointer class handles touch interactions with the game and the resulting Pointer objects. * It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 apps using JavaScript. * http://msdn.microsoft.com/en-us/library/ie/hh673557(v=vs.85).aspx +* +* @class Phaser.MSPointer * @constructor * @param {Phaser.Game} game - A reference to the currently running game. */ @@ -637,8 +644,9 @@ Phaser.MSPointer.prototype = { /** * The function that handles the PointerDown event. + * * @method Phaser.MSPointer#onPointerDown - * @param {PointerEvent} event + * @param {PointerEvent} event - The native DOM event. */ onPointerDown: function (event) { @@ -657,7 +665,7 @@ Phaser.MSPointer.prototype = { /** * The function that handles the PointerMove event. * @method Phaser.MSPointer#onPointerMove - * @param {PointerEvent } event + * @param {PointerEvent} event - The native DOM event. */ onPointerMove: function (event) { @@ -676,7 +684,7 @@ Phaser.MSPointer.prototype = { /** * The function that handles the PointerUp event. * @method Phaser.MSPointer#onPointerUp - * @param {PointerEvent} event + * @param {PointerEvent} event - The native DOM event. */ onPointerUp: function (event) { @@ -732,7 +740,7 @@ Phaser.MSPointer.prototype.constructor = Phaser.MSPointer; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Material.js.html b/docs/Material.js.html index 24ebec80d..b5f5f26c8 100644 --- a/docs/Material.js.html +++ b/docs/Material.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,11 +551,13 @@ */ /** +* A P2 Material. +* * \o/ ~ "Because I'm a Material girl" * * @class Phaser.Physics.P2.Material -* @classdesc Physics Material Constructor * @constructor +* @param {string} name - The user defined name given to this Material. */ Phaser.Physics.P2.Material = function (name) { @@ -584,7 +594,7 @@ Phaser.Physics.P2.Material.prototype.constructor = Phaser.Physics.P2.Material; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Math.js.html b/docs/Math.js.html index 3fce3efba..2c56f665c 100644 --- a/docs/Math.js.html +++ b/docs/Math.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1427,7 +1435,7 @@ Phaser.Math = { * * @method Phaser.Math#wrapAngle * @param {number} angle - The angle value to check - * @param {boolean} radians - True if angle is given in radians. + * @param {boolean} radians - Set to `true` if the angle is given in radians, otherwise degrees is expected. * @return {number} The new angle value, returns the same as the input angle if it was within bounds. */ wrapAngle: function (angle, radians) { @@ -2045,7 +2053,7 @@ Phaser.Math = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Mouse.js.html b/docs/Mouse.js.html index 508233699..5c98e329e 100644 --- a/docs/Mouse.js.html +++ b/docs/Mouse.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1101,7 +1109,7 @@ Phaser.Mouse.prototype.constructor = Phaser.Mouse; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Net.js.html b/docs/Net.js.html index 77a420ab8..7b1c3579c 100644 --- a/docs/Net.js.html +++ b/docs/Net.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -723,7 +731,7 @@ Phaser.Net.prototype.constructor = Phaser.Net; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Particle.js.html b/docs/Particle.js.html index dc34aa7e3..f16754359 100644 --- a/docs/Particle.js.html +++ b/docs/Particle.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,10 +551,9 @@ */ /** +* Create a new `Particle` object. Particles are extended Sprites that are emitted by a particle emitter such as Phaser.Particles.Arcade.Emitter. +* * @class Phaser.Particle -* -* @classdesc Create a new `Particle` object. Particles are extended Sprites that are emitted by a particle emitter such as Phaser.Particles.Arcade.Emitter. -* * @constructor * @extends Phaser.Sprite * @param {Phaser.Game} game - A reference to the currently running game. @@ -741,7 +748,7 @@ Phaser.Particle.prototype.reset = function(x, y, health) { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Particles.js.html b/docs/Particles.js.html index a1c770eb9..2df4ac928 100644 --- a/docs/Particles.js.html +++ b/docs/Particles.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * Phaser.Particles is the Particle Manager for the game. It is called during the game update loop and in turn updates any Emitters attached to it. * * @class Phaser.Particles -* @classdesc Phaser Particles * @constructor * @param {Phaser.Game} game - A reference to the currently running game. */ @@ -638,7 +645,7 @@ Phaser.Particles.prototype.constructor = Phaser.Particles; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Animation.html b/docs/Phaser.Animation.html index bd4f426f7..702740bcc 100644 --- a/docs/Phaser.Animation.html +++ b/docs/Phaser.Animation.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -4527,7 +4535,7 @@ If dispatchComplete is true it will dispatch the complete events, o Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:46 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.AnimationManager.html b/docs/Phaser.AnimationManager.html index daf73bea0..8338a39b4 100644 --- a/docs/Phaser.AnimationManager.html +++ b/docs/Phaser.AnimationManager.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -982,7 +990,7 @@ Any Game Object such as Phaser.Sprite that supports animation contains a single
    Source:
    @@ -1084,7 +1092,7 @@ Any Game Object such as Phaser.Sprite that supports animation contains a single
    Source:
    @@ -1186,7 +1194,7 @@ Any Game Object such as Phaser.Sprite that supports animation contains a single
    Source:
    @@ -1288,7 +1296,7 @@ Any Game Object such as Phaser.Sprite that supports animation contains a single
    Source:
    @@ -1504,6 +1512,108 @@ Any Game Object such as Phaser.Sprite that supports animation contains a single + + + + + + + + +
    +

    name

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    name + + +string + + + +

    Gets the current animation name, if set.

    +
    + + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + +
    @@ -1597,7 +1707,7 @@ Any Game Object such as Phaser.Sprite that supports animation contains a single
    Source:
    @@ -2091,7 +2201,7 @@ Animations added in this way are played back with the play function.

    Source:
    @@ -2184,7 +2294,7 @@ Iterates through the list of animations stored in this manager and calls destroy
    Source:
    @@ -2302,7 +2412,7 @@ Iterates through the list of animations stored in this manager and calls destroy
    Source:
    @@ -2463,7 +2573,7 @@ Iterates through the list of animations stored in this manager and calls destroy
    Source:
    @@ -2715,7 +2825,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -2876,7 +2986,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -2945,7 +3055,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -3123,7 +3233,7 @@ The currentAnim property of the AnimationManager is automatically set to the ani
    Source:
    @@ -3192,7 +3302,7 @@ The currentAnim property of the AnimationManager is automatically set to the ani
    Source:
    @@ -3388,7 +3498,7 @@ The currentAnim property of the AnimationManager is automatically set to the ani
    Source:
    @@ -3462,7 +3572,7 @@ The currentAnim property of the AnimationManager is automatically set to the ani Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:19 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:46 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.AnimationParser.html b/docs/Phaser.AnimationParser.html index ca5539725..cca8552d9 100644 --- a/docs/Phaser.AnimationParser.html +++ b/docs/Phaser.AnimationParser.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1601,7 +1609,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:19 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:46 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.ArrayList.html b/docs/Phaser.ArrayList.html index f2cbb5c4e..c50915da1 100644 --- a/docs/Phaser.ArrayList.html +++ b/docs/Phaser.ArrayList.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -2127,7 +2135,7 @@ The function must exist on the member.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:19 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:47 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.AudioSprite.html b/docs/Phaser.AudioSprite.html new file mode 100644 index 000000000..2f7b86e16 --- /dev/null +++ b/docs/Phaser.AudioSprite.html @@ -0,0 +1,1914 @@ + + + + + + Phaser Class: AudioSprite + + + + + + + + + + +
    + + +
    + + +
    + +
    + + + +

    Class: AudioSprite

    +
    + +
    +

    + Phaser. + + AudioSprite +

    + +

    Phaser.AudioSprite

    + +
    + +
    +
    + + + + +
    +

    new AudioSprite(game, key)

    + + +
    +
    + + +
    +

    Audio Sprites are a combination of audio files and a JSON configuration. +The JSON follows the format of that created by https://github.com/tonistiigi/audiosprite

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    game + + +Phaser.Game + + + +

    Reference to the current game instance.

    key + + +string + + + +

    Asset key for the sound.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + + + +
    + + +
    + + + + + + + + + + + + +

    Members

    + +
    + +
    +

    autoplay

    + + +
    +
    + +
    +

    Is a sound set to autoplay or not?

    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    autoplay + + +boolean + + + +
    +
    + + + + + + + + + + + + + + + + + + +
    Default Value:
    +
    • false
    + + + +
    Source:
    +
    + + + + + + + +
    + + + +
    + + + +
    +

    autoplayKey

    + + +
    +
    + +
    +

    If a sound is set to auto play, this holds the marker key of it.

    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    autoplayKey + + +string + + + +
    +
    + + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + +
    + + + +
    +

    config

    + + +
    +
    + +
    +

    JSON audio atlas object.

    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    config + + +object + + + +
    +
    + + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + +
    + + + +
    +

    game

    + + +
    +
    + +
    +

    A reference to the currently running Game.

    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    game + + +Phaser.Game + + + +
    +
    + + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + +
    + + + +
    +

    key

    + + +
    +
    + +
    +

    Asset key for the Audio Sprite.

    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    key + + +string + + + +
    +
    + + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + +
    + + + +
    +

    sounds

    + + +
    +
    + +
    +

    An object containing the Phaser.Sound objects for the Audio Sprite.

    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    sounds + + +object + + + +
    +
    + + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + +
    + +
    + + + +

    Methods

    + +
    + +
    +

    get(marker) → {Phaser.Sound}

    + + +
    +
    + + +
    +

    Get a sound with the given name.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    marker + + +string + + + +

    The name of sound to get.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    The sound instance.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.Sound + + +
    +
    + + + + + +
    + + + +
    +

    play(marker, volume) → {Phaser.Sound}

    + + +
    +
    + + +
    +

    Play a sound with the given name.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    marker + + +string + + + + + + <optional>
    + + + + + +
    + +

    The name of sound to play

    volume + + +number + + + + + + <optional>
    + + + + + +
    + + 1 + +

    Volume of the sound you want to play. If none is given it will use the volume given to the Sound when it was created (which defaults to 1 if none was specified).

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    This sound instance.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.Sound + + +
    +
    + + + + + +
    + + + +
    +

    stop(marker)

    + + +
    +
    + + +
    +

    Stop a sound with the given name.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    marker + + +string + + + + + + <optional>
    + + + + + +
    + + '' + +

    The name of sound to stop. If none is given it will stop all sounds in the audio sprite.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + + + +
    + +
    + + + + + +
    + +
    + + + + +
    + +
    +
    + + + + Phaser Copyright © 2012-2014 Photon Storm Ltd. + +
    + + + Documentation generated by JSDoc 3.3.0-dev + on Thu Oct 09 2014 16:09:47 GMT+0100 (BST) using the DocStrap template. + +
    +
    + + +
    +
    +
    + +
    +
    + +
    + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/Phaser.BitmapData.html b/docs/Phaser.BitmapData.html index 247161ac7..df9a49d59 100644 --- a/docs/Phaser.BitmapData.html +++ b/docs/Phaser.BitmapData.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,8 +550,7 @@ BitmapData -

    A BitmapData object contains a Canvas element to which you can draw anything you like via normal Canvas context operations. -A single BitmapData can be used as the texture for one or many Images/Sprites. So if you need to dynamically create a Sprite texture then they are a good choice.

    +

    Phaser.BitmapData

    @@ -562,7 +569,9 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    -

    Creates a new BitmapData object.

    +

    A BitmapData object contains a Canvas element to which you can draw anything you like via normal Canvas context operations. +A single BitmapData can be used as the texture for one or many Images/Sprites. +So if you need to dynamically create a Sprite texture then they are a good choice.

    @@ -773,7 +782,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -901,7 +910,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -1003,7 +1012,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -1105,7 +1114,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -1207,7 +1216,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -1309,7 +1318,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -1411,7 +1420,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -1513,7 +1522,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -1615,7 +1624,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -1717,7 +1726,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -1819,7 +1828,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -1921,7 +1930,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -2023,7 +2032,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -2125,7 +2134,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -2227,7 +2236,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -2329,7 +2338,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -2431,7 +2440,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -2533,7 +2542,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -2762,7 +2771,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -2912,7 +2921,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -3268,7 +3277,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -3319,7 +3328,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    -

    alphaMask(source, mask) → {Phaser.BitmapData}

    +

    alphaMask(source, mask, sourceRect, maskRect) → {Phaser.BitmapData}

    @@ -3460,6 +3469,72 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S + + + + sourceRect + + + + + +Phaser.Rectangle + + + + + + + + + <optional>
    + + + + + + + + + + +

    A Rectangle where x/y define the coordinates to draw the Source image to and width/height define the size.

    + + + + + + + maskRect + + + + + +Phaser.Rectangle + + + + + + + + + <optional>
    + + + + + + + + + + +

    A Rectangle where x/y define the coordinates to draw the Mask image to and width/height define the size.

    + + + @@ -3488,7 +3563,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -3580,7 +3655,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -3672,7 +3747,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -3764,7 +3839,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -3856,7 +3931,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -3948,7 +4023,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4040,7 +4115,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4132,7 +4207,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4224,7 +4299,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4316,7 +4391,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4408,7 +4483,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4500,7 +4575,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4592,7 +4667,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4684,7 +4759,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4776,7 +4851,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4868,7 +4943,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -4960,7 +5035,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -5052,7 +5127,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -5144,7 +5219,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -5236,7 +5311,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -5328,7 +5403,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -5420,7 +5495,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -5512,7 +5587,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -5604,7 +5679,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -5696,7 +5771,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -5788,7 +5863,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -5880,7 +5955,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -6126,7 +6201,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -6218,7 +6293,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -6310,7 +6385,7 @@ A single BitmapData can be used as the texture for one or many Images/Sprites. S
    Source:
    @@ -7081,7 +7156,7 @@ You can use the more friendly methods like copyRect and draw<
    Source:
    @@ -7475,7 +7550,7 @@ You can use the more friendly methods like copyRect and draw<
    Source:
    @@ -7870,7 +7945,7 @@ When drawing it will take into account the Sprites rotation, scale and alpha val
    Source:
    @@ -8328,7 +8403,7 @@ the color during extraction.

    Source:
    @@ -8594,7 +8669,7 @@ the color during extraction.

    Source:
    @@ -8811,7 +8886,7 @@ otherwise this may return out of date color values, or worse - throw a run-time
    Source:
    @@ -8978,7 +9053,7 @@ Note that on little-endian systems the format is 0xAABBGGRR and on big-endian th
    Source:
    @@ -9287,7 +9362,7 @@ otherwise this may return out of date color values, or worse - throw a run-time
    Source:
    @@ -9428,7 +9503,7 @@ otherwise this may return out of date color values, or worse - throw a run-time
    Source:
    @@ -9590,7 +9665,7 @@ If a string is given it will assume it's a cache key and look in Phaser.Cache fo
    Source:
    @@ -9938,7 +10013,7 @@ The callback will also be sent the pixels x and y coordinates respectively.

    Source:
    @@ -10289,7 +10364,7 @@ If a new color object is returned the pixel will be set to the r, g, b and a col
    Source:
    @@ -10566,7 +10641,7 @@ If a new color object is returned the pixel will be set to the r, g, b and a col
    Source:
    @@ -10660,7 +10735,7 @@ If you wish to suppress this functionality set BitmapData.disableTextureUpload t
    Source:
    @@ -11062,7 +11137,7 @@ An optional region parameter controls if the replacement happens in just a speci
    Source:
    @@ -11154,7 +11229,7 @@ An optional region parameter controls if the replacement happens in just a speci
    Source:
    @@ -11430,7 +11505,7 @@ An optional region parameter controls if the replacement happens in just a speci
    Source:
    @@ -11801,7 +11876,7 @@ An optional region parameter controls if the replacement happens in just a speci
    Source:
    @@ -12172,7 +12247,283 @@ An optional region parameter controls if the replacement happens in just a speci
    Source:
    + + + + + + + + + + + + + + + + + + + +
    Returns:
    + + +
    +

    This BitmapData object for method chaining.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.BitmapData + + +
    +
    + + + + + + + + + +
    +

    shadow(color, blur, x, y) → {Phaser.BitmapData}

    + + +
    +
    + + +
    +

    Sets the shadow properties of this BitmapDatas context which will affect all draw operations made to it. +You can cancel an existing shadow by calling this method and passing no parameters. +Note: At the time of writing (October 2014) Chrome still doesn't support shadowBlur used with drawImage.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    color + + +string + + + + + + + + + + + +

    The color of the shadow, given in a CSS format, i.e. #000000 or rgba(0,0,0,1). If null or undefined the shadow will be reset.

    blur + + +number + + + + + + <optional>
    + + + + + +
    + + 5 + +

    The amount the shadow will be blurred by. Low values = a crisp shadow, high values = a softer shadow.

    x + + +number + + + + + + <optional>
    + + + + + +
    + + 10 + +

    The horizontal offset of the shadow in pixels.

    y + + +number + + + + + + <optional>
    + + + + + +
    + + 10 + +

    The vertical offset of the shadow in pixels.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -12450,7 +12801,241 @@ The hue is wrapped to keep it within the range 0 to 1. Saturation and lightness
    Source:
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    This BitmapData object for method chaining.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.BitmapData + + +
    +
    + + + + + +
    + + + +
    +

    textureLine(line, image, repeat) → {Phaser.BitmapData}

    + + +
    +
    + + +
    +

    Takes the given Line object and image and renders it to this BitmapData as a repeating texture line.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    line + + +Phaser.Line + + + + + + + + + + + +

    A Phaser.Line object that will be used to plot the start and end of the line.

    image + + +string +| + +HTMLImage + + + + + + + + + + + +

    The key of an image in the Phaser.Cache to use as the texture for this line, or an actual Image.

    repeat + + +string + + + + + + <optional>
    + + + + + +
    + + 'repeat-x' + +

    The pattern repeat mode to use when drawing the line. Either repeat, repeat-x or no-repeat.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -12726,7 +13311,7 @@ If not given the dimensions defaults to the full size of the context.

    Source:
    @@ -12800,7 +13385,7 @@ If not given the dimensions defaults to the full size of the context.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:19 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:47 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.BitmapText.html b/docs/Phaser.BitmapText.html index f2c482909..3077f183b 100644 --- a/docs/Phaser.BitmapText.html +++ b/docs/Phaser.BitmapText.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,10 +550,7 @@ BitmapText -

    BitmapText objects work by taking a texture file and an XML file that describes the font layout.

    -

    On Windows you can use the free app BMFont: http://www.angelcode.com/products/bmfont/ -On OS X we recommend Glyph Designer: http://www.71squared.com/en/glyphdesigner -For Web there is the great Littera: http://kvazars.com/littera/

    +

    Phaser.BitmapText

    @@ -564,7 +569,10 @@ For Web there is the great Littera: http:/ @@ -845,7 +853,7 @@ For Web there is the great Littera: http:/
    Source:
    @@ -874,6 +882,12 @@ For Web there is the great Littera: http:/ +

    Extends

    + +
      +
    • PIXI.BitmapText
    • +
    + @@ -973,7 +987,7 @@ For Web there is the great Littera:
    http:/
    Source:
    @@ -1081,7 +1095,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1183,7 +1197,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1285,7 +1299,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1387,7 +1401,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1492,7 +1506,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1600,7 +1614,7 @@ So if this BitmapText was in a Group that has x: 200, then this will be added to
    Source:
    @@ -1702,7 +1716,7 @@ So if this BitmapText was in a Group that has x: 200, then this will be added to
    Source:
    @@ -1804,7 +1818,7 @@ So if this BitmapText was in a Group that has x: 200, then this will be added to
    Source:
    @@ -1906,7 +1920,7 @@ So if this BitmapText was in a Group that has x: 200, then this will be added to
    Source:
    @@ -2011,7 +2025,7 @@ So if this BitmapText was in a Group that has x: 200, then this will be added to
    Source:
    @@ -2118,7 +2132,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2220,7 +2234,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2322,7 +2336,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2428,7 +2442,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2530,7 +2544,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2632,7 +2646,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2734,7 +2748,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2836,7 +2850,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2938,7 +2952,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3072,7 +3086,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3141,7 +3155,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3210,7 +3224,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3279,7 +3293,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3330,7 +3344,7 @@ activated for this object and it will then start to process click/touch events a Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:20 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:47 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Button.html b/docs/Phaser.Button.html index 0fede32e4..65d057f83 100644 --- a/docs/Phaser.Button.html +++ b/docs/Phaser.Button.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,14 +550,7 @@ Button -

    Create a new Button object. A Button is a special type of Sprite that is set-up to handle Pointer events automatically. The four states a Button responds to are:

    -
      -
    • 'Over' - when the Pointer moves over the Button. This is also commonly known as 'hover'.
    • -
    • 'Out' - when the Pointer that was previously over the Button moves out of it.
    • -
    • 'Down' - when the Pointer is pressed down on the Button. I.e. touched on a touch enabled device or clicked with the mouse.
    • -
    • 'Up' - when the Pointer that was pressed down on the Button is released again.
    • -
    -

    You can set a unique texture frame and Sound for any of these states.

    +

    Phaser.Button

    @@ -567,6 +568,17 @@
    +
    +

    Create a new Button object. A Button is a special type of Sprite that is set-up to handle Pointer events automatically. The four states a Button responds to are:

    +
      +
    • 'Over' - when the Pointer moves over the Button. This is also commonly known as 'hover'.
    • +
    • 'Out' - when the Pointer that was previously over the Button moves out of it.
    • +
    • 'Down' - when the Pointer is pressed down on the Button. I.e. touched on a touch enabled device or clicked with the mouse.
    • +
    • 'Up' - when the Pointer that was pressed down on the Button is released again.
    • +
    +

    You can set a unique texture frame and Sound for any of these states.

    +
    + @@ -1011,7 +1023,7 @@
    Source:
    @@ -1266,7 +1278,7 @@ If you wish to work in radians instead of degrees use the property Image.rotatio
    Source:
    @@ -1927,7 +1939,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -2038,7 +2050,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -2149,7 +2161,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -2256,7 +2268,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -2586,7 +2598,7 @@ So if this Image was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2695,7 +2707,7 @@ So if this Image was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2802,7 +2814,7 @@ So if this Image was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2909,7 +2921,7 @@ So if this Image was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3011,7 +3023,7 @@ So if this Image was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3229,7 +3241,7 @@ So if this Image was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3451,7 +3463,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3562,7 +3574,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3890,7 +3902,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3992,7 +4004,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4094,7 +4106,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4196,7 +4208,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4298,7 +4310,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4400,7 +4412,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4505,7 +4517,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4607,7 +4619,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4712,7 +4724,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4817,7 +4829,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4919,7 +4931,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -5024,7 +5036,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -5126,7 +5138,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -5233,7 +5245,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -5344,7 +5356,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -5446,7 +5458,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -5731,7 +5743,7 @@ bought to the top of that Group, not the entire display list.

    Source:
    @@ -5823,7 +5835,7 @@ bought to the top of that Group, not the entire display list.

    Source:
    @@ -6005,7 +6017,7 @@ Keep this in mind if assigning a rectangle in a for-loop, or when cleaning up fo
    Source:
    @@ -6149,7 +6161,7 @@ and nulls its reference to game, freeing it up for garbage collection.

    Source:
    @@ -6226,7 +6238,7 @@ If you don't need this Image any more you should call Image.destroy instead.

    Source:
    @@ -6549,7 +6561,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -6690,7 +6702,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -6831,7 +6843,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -6972,7 +6984,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -7266,7 +7278,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -7363,7 +7375,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -7439,7 +7451,7 @@ It will dispatch the onRevived event, you can listen to Image.events.onRevived f
    Source:
    @@ -7623,7 +7635,7 @@ It will dispatch the onRevived event, you can listen to Image.events.onRevived f
    Source:
    @@ -7747,7 +7759,7 @@ This is primarily an internal method used by Image.loadTexture, although you may
    Source:
    @@ -7988,7 +8000,7 @@ This is primarily an internal method used by Image.loadTexture, although you may
    Source:
    @@ -8149,7 +8161,7 @@ This is primarily an internal method used by Image.loadTexture, although you may
    Source:
    @@ -8310,7 +8322,7 @@ This is primarily an internal method used by Image.loadTexture, although you may
    Source:
    @@ -8673,7 +8685,7 @@ Call this function with no parameters at all to reset all sounds on this Button.
    Source:
    @@ -8791,7 +8803,7 @@ Call this function with no parameters at all to reset all sounds on this Button.
    Source:
    @@ -8952,7 +8964,7 @@ Call this function with no parameters at all to reset all sounds on this Button.
    Source:
    @@ -9101,7 +9113,7 @@ then you need to update the crop frame by calling this method.

    Source:
    @@ -9152,7 +9164,7 @@ then you need to update the crop frame by calling this method.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:20 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:48 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Cache.html b/docs/Phaser.Cache.html index 465900a07..3d49681b3 100644 --- a/docs/Phaser.Cache.html +++ b/docs/Phaser.Cache.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Cache -

    A game only has one instance of a Cache and it is used to store all externally loaded assets such as images, sounds and data files as a result of Loader calls. Cached items use string based keys for look-up.

    +

    Phaser.Cache

    @@ -561,7 +569,8 @@
    -

    Phaser.Cache constructor.

    +

    A game only has one instance of a Cache and it is used to store all externally loaded assets such as images, sounds +and data files as a result of Loader calls. Cached items use string based keys for look-up.

    @@ -729,7 +738,7 @@
    Source:
    @@ -789,7 +798,7 @@
    Source:
    @@ -849,7 +858,7 @@
    Source:
    @@ -909,7 +918,7 @@
    Source:
    @@ -969,7 +978,7 @@
    Source:
    @@ -1029,7 +1038,7 @@
    Source:
    @@ -1089,7 +1098,7 @@
    Source:
    @@ -1149,7 +1158,7 @@
    Source:
    @@ -1209,7 +1218,7 @@
    Source:
    @@ -1269,7 +1278,7 @@
    Source:
    @@ -1329,7 +1338,67 @@
    Source:
    + + + + + + + +
    + + + +
    + + + +
    +

    <static, constant> XML :number

    + + +
    +
    + + + +
    Type:
    +
      +
    • + +number + + +
    • +
    + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -1431,7 +1500,7 @@
    Source:
    @@ -1635,7 +1704,7 @@
    Source:
    @@ -1772,7 +1841,7 @@
    Source:
    @@ -1800,7 +1869,7 @@
    -

    addBitmapData(key, bitmapData) → {Phaser.BitmapData}

    +

    addBitmapData(key, bitmapData, frameData) → {Phaser.BitmapData}

    @@ -1830,6 +1899,8 @@ Type + Argument + @@ -1855,6 +1926,14 @@ + + + + + + + + @@ -1878,6 +1957,14 @@ + + + + + + + + @@ -1885,6 +1972,39 @@ + + + + frameData + + + + + +Phaser.FrameData + + + + + + + + + <optional>
    + + + + + + + + + + +

    Optional FrameData set associated with the given BitmapData.

    + + + @@ -1913,7 +2033,7 @@
    Source:
    @@ -2253,7 +2373,7 @@
    Source:
    @@ -2417,7 +2537,7 @@
    Source:
    @@ -2486,7 +2606,7 @@
    Source:
    @@ -2650,7 +2770,7 @@
    Source:
    @@ -2736,7 +2856,7 @@ -

    Asset key for the text data.

    +

    Asset key for the json data.

    @@ -2759,7 +2879,7 @@ -

    URL of this text data file.

    +

    URL of this json data file.

    @@ -2782,7 +2902,7 @@ -

    Extra text data.

    +

    Extra json data.

    @@ -2814,7 +2934,7 @@
    Source:
    @@ -2883,7 +3003,7 @@
    Source:
    @@ -3024,7 +3144,7 @@
    Source:
    @@ -3234,7 +3354,7 @@
    Source:
    @@ -3625,7 +3745,7 @@
    Source:
    @@ -3789,7 +3909,7 @@
    Source:
    @@ -3999,7 +4119,7 @@
    Source:
    @@ -4186,7 +4306,7 @@
    Source:
    @@ -4373,7 +4493,171 @@
    Source:
    + + + + + + + +
    + + + + + + + + + + + + + +
    + + + +
    +

    addXML(key, url, data)

    + + +
    +
    + + +
    +

    Add a new xml object into the cache.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    key + + +string + + + +

    Asset key for the xml file.

    url + + +string + + + +

    URL of this xml file.

    data + + +object + + + +

    Extra text data.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -4459,7 +4743,7 @@ -

    Asset key of the image to check is in the Cache.

    +

    Asset key of the binary file to check is in the Cache.

    @@ -4491,7 +4775,7 @@
    Source:
    @@ -4600,7 +4884,7 @@ -

    Asset key of the image to check is in the Cache.

    +

    Asset key of the BitmapData to check is in the Cache.

    @@ -4632,7 +4916,7 @@
    Source:
    @@ -4741,7 +5025,7 @@ -

    Asset key of the image to check is in the Cache.

    +

    Asset key of the BitmapFont to check is in the Cache.

    @@ -4773,7 +5057,7 @@
    Source:
    @@ -4882,7 +5166,7 @@ -

    Asset key of the image to check is in the Cache.

    +

    Asset key of the canvas to check is in the Cache.

    @@ -4914,7 +5198,7 @@
    Source:
    @@ -5055,7 +5339,7 @@
    Source:
    @@ -5164,7 +5448,7 @@ -

    Asset key of the image to check is in the Cache.

    +

    Asset key of the JSON file to check is in the Cache.

    @@ -5196,7 +5480,7 @@
    Source:
    @@ -5360,7 +5644,7 @@
    Source:
    @@ -5469,7 +5753,7 @@ -

    Asset key of the image to check is in the Cache.

    +

    Asset key of the physics data file to check is in the Cache.

    @@ -5501,7 +5785,7 @@
    Source:
    @@ -5610,7 +5894,7 @@ -

    Asset key of the image to check is in the Cache.

    +

    Asset key of the sound file to check is in the Cache.

    @@ -5642,7 +5926,7 @@
    Source:
    @@ -5751,7 +6035,7 @@ -

    Asset key of the image to check is in the Cache.

    +

    Asset key of the text file to check is in the Cache.

    @@ -5783,7 +6067,7 @@
    Source:
    @@ -5924,7 +6208,7 @@
    Source:
    @@ -6033,7 +6317,7 @@ -

    Asset key of the image to check is in the Cache.

    +

    Asset key of the Tilemap to check is in the Cache.

    @@ -6065,7 +6349,289 @@
    Source:
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    True if the key exists, otherwise false.

    +
    + + + +
    +
    + Type +
    +
    + +boolean + + +
    +
    + + + + + +
    + + + +
    +

    checkUrl(url) → {boolean}

    + + +
    +
    + + +
    +

    Checks if the given URL has been loaded into the Cache.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    url + + +string + + + +

    The url to check for in the cache.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    True if the url exists, otherwise false.

    +
    + + + +
    +
    + Type +
    +
    + +boolean + + +
    +
    + + + + + +
    + + + +
    +

    checkXMLKey(key) → {boolean}

    + + +
    +
    + + +
    +

    Checks if the given key exists in the XML Cache.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    key + + +string + + + +

    Asset key of the XML file to check is in the Cache.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -6229,7 +6795,7 @@
    Source:
    @@ -6298,7 +6864,7 @@
    Source:
    @@ -6416,7 +6982,7 @@
    Source:
    @@ -6557,7 +7123,7 @@
    Source:
    @@ -6698,7 +7264,7 @@
    Source:
    @@ -6839,7 +7405,7 @@
    Source:
    @@ -6980,7 +7546,7 @@
    Source:
    @@ -7121,7 +7687,7 @@
    Source:
    @@ -7262,7 +7828,7 @@
    Source:
    @@ -7403,7 +7969,7 @@
    Source:
    @@ -7454,7 +8020,7 @@
    -

    getFrameData(key) → {Phaser.FrameData}

    +

    getFrameData(key, map) → {Phaser.FrameData}

    @@ -7484,8 +8050,12 @@ Type + Argument + + Default + Description @@ -7509,13 +8079,64 @@ + + + + + + + + + + + +

    Asset key of the frame data to retrieve from the Cache.

    + + + + map + + + + + +string + + + + + + + + + <optional>
    + + + + + + + + + + + + Phaser.Cache.IMAGE + + + + +

    The asset map to get the frameData from, for example Phaser.Cache.IMAGE.

    + + + @@ -7544,7 +8165,7 @@
    Source:
    @@ -7685,7 +8306,7 @@
    Source:
    @@ -7826,7 +8447,7 @@
    Source:
    @@ -7987,7 +8608,7 @@
    Source:
    @@ -8218,7 +8839,7 @@
    Source:
    @@ -8359,7 +8980,7 @@
    Source:
    @@ -8500,7 +9121,7 @@
    Source:
    @@ -8641,7 +9262,7 @@
    Source:
    @@ -8782,7 +9403,7 @@
    Source:
    @@ -8923,7 +9544,7 @@
    Source:
    @@ -9064,7 +9685,7 @@
    Source:
    @@ -9110,6 +9731,288 @@ +
    + + + +
    +

    getUrl(url) → {object}

    + + +
    +
    + + +
    +

    Get a cached object by the URL.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    url + + +string + + + +

    The url for the object loaded to get from the cache.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    The cached object.

    +
    + + + +
    +
    + Type +
    +
    + +object + + +
    +
    + + + + + +
    + + + +
    +

    getXML(key) → {object}

    + + +
    +
    + + +
    +

    Get a XML object by key from the cache.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    key + + +string + + + +

    Asset key of the XML object to retrieve from the Cache.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    The XML object.

    +
    + + + +
    +
    + Type +
    +
    + +object + + +
    +
    + + + + +
    @@ -9205,7 +10108,7 @@
    Source:
    @@ -9346,7 +10249,7 @@
    Source:
    @@ -9487,7 +10390,7 @@
    Source:
    @@ -9605,7 +10508,7 @@
    Source:
    @@ -9723,7 +10626,7 @@
    Source:
    @@ -9841,7 +10744,7 @@
    Source:
    @@ -9959,7 +10862,7 @@
    Source:
    @@ -10077,7 +10980,7 @@
    Source:
    @@ -10105,7 +11008,7 @@
    -

    removeImage(key)

    +

    removeImage(key, removeFromPixi)

    @@ -10113,7 +11016,7 @@
    -

    Removes an image from the cache.

    +

    Removes an image from the cache and optionally from the Pixi.BaseTextureCache as well.

    @@ -10135,8 +11038,12 @@ Type + Argument + + Default + Description @@ -10160,13 +11067,64 @@ + + + + + + + + + + + +

    Key of the asset you want to remove.

    + + + + removeFromPixi + + + + + +boolean + + + + + + + + + <optional>
    + + + + + + + + + + + + true + + + + +

    Should this image also be removed from the Pixi BaseTextureCache?

    + + + @@ -10195,7 +11153,7 @@
    Source:
    @@ -10313,7 +11271,7 @@
    Source:
    @@ -10431,7 +11389,7 @@
    Source:
    @@ -10549,7 +11507,7 @@
    Source:
    @@ -10667,7 +11625,7 @@
    Source:
    @@ -10785,7 +11743,125 @@
    Source:
    + + + + + + + + + + + + + + + + + + + + + + + + + +
    +

    removeXML(key)

    + + +
    +
    + + +
    +

    Removes a xml object from the cache.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    key + + +string + + + +

    Key of the asset you want to remove.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -10926,7 +12002,7 @@
    Source:
    @@ -11044,7 +12120,7 @@
    Source:
    @@ -11095,7 +12171,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:20 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:48 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Camera.html b/docs/Phaser.Camera.html index 75084e313..7c475a13e 100644 --- a/docs/Phaser.Camera.html +++ b/docs/Phaser.Camera.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -845,7 +853,7 @@ The game automatically creates a single Stage sized camera on boot. Move the cam
    Source:
    @@ -905,7 +913,7 @@ The game automatically creates a single Stage sized camera on boot. Move the cam
    Source:
    @@ -965,7 +973,7 @@ The game automatically creates a single Stage sized camera on boot. Move the cam
    Source:
    @@ -1025,7 +1033,109 @@ The game automatically creates a single Stage sized camera on boot. Move the cam
    Source:
    + + + + + + + +
    + + + +
    + + + +
    +

    _targetPosition

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    _targetPosition + + +Phaser.Point + + + +

    Internal point used to calculate target position

    +
    + + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -1647,7 +1757,7 @@ at all then set this to null. The values can be anything and are in World coordi
    Source:
    @@ -1858,7 +1968,7 @@ at all then set this to null. The values can be anything and are in World coordi
    Source:
    @@ -2592,7 +2702,7 @@ Objects outside of this view are not rendered if set to camera cull.

    Source:
    @@ -2800,7 +2910,7 @@ Objects outside of this view are not rendered if set to camera cull.

    Source:
    @@ -2906,7 +3016,7 @@ Objects outside of this view are not rendered if set to camera cull.

    Source:
    @@ -2971,7 +3081,7 @@ Objects outside of this view are not rendered if set to camera cull.

    Source:
    @@ -3089,7 +3199,7 @@ Objects outside of this view are not rendered if set to camera cull.

    Source:
    @@ -3230,7 +3340,7 @@ Objects outside of this view are not rendered if set to camera cull.

    Source:
    @@ -3397,7 +3507,7 @@ Objects outside of this view are not rendered if set to camera cull.

    Source:
    @@ -3466,7 +3576,7 @@ Objects outside of this view are not rendered if set to camera cull.

    Source:
    @@ -3535,7 +3645,7 @@ Objects outside of this view are not rendered if set to camera cull.

    Source:
    @@ -3677,7 +3787,7 @@ without having to use game.camera.x and game.camera.y.

    Source:
    @@ -3818,7 +3928,7 @@ without having to use game.camera.x and game.camera.y.

    Source:
    @@ -3887,7 +3997,7 @@ without having to use game.camera.x and game.camera.y.

    Source:
    @@ -3956,7 +4066,7 @@ without having to use game.camera.x and game.camera.y.

    Source:
    @@ -4007,7 +4117,7 @@ without having to use game.camera.x and game.camera.y.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:21 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:48 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Canvas.html b/docs/Phaser.Canvas.html index cbf19e233..2d5ee04f2 100644 --- a/docs/Phaser.Canvas.html +++ b/docs/Phaser.Canvas.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -3004,7 +3012,7 @@ patchy on earlier browsers, especially on mobile.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:21 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:49 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Circle.html b/docs/Phaser.Circle.html index 7e422adda..c9b6ea032 100644 --- a/docs/Phaser.Circle.html +++ b/docs/Phaser.Circle.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Circle -

    Phaser - Circle

    +

    Phaser.Circle

    @@ -553,7 +561,7 @@
    -

    new Circle(x, y, diameter) → {Phaser.Circle}

    +

    new Circle(x, y, diameter)

    @@ -561,7 +569,8 @@
    -

    Creates a new Circle object with the center coordinate specified by the x and y parameters and the diameter specified by the diameter parameter. If you call this function without parameters, a circle with x, y, diameter and radius properties set to 0 is created.

    +

    Creates a new Circle object with the center coordinate specified by the x and y parameters and the diameter specified by the diameter parameter. +If you call this function without parameters, a circle with x, y, diameter and radius properties set to 0 is created.

    @@ -762,29 +771,6 @@ -
    Returns:
    - - -
    -

    This circle object

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Circle - - -
    -
    - - -
    @@ -1535,7 +1521,7 @@ If set to true it will reset all of the Circle objects properties to 0. A Circle
    Source:
    @@ -4319,7 +4305,7 @@ This method checks the radius distances between the two Circle objects to see if -

    The diameter of the circle in pixels.

    +

    The diameter of the circle.

    @@ -4517,7 +4503,7 @@ This method checks the radius distances between the two Circle objects to see if Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:21 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:49 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Color.html b/docs/Phaser.Color.html index 559f7ed85..9e827e6bb 100644 --- a/docs/Phaser.Color.html +++ b/docs/Phaser.Color.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -728,7 +736,7 @@
    Source:
    @@ -1504,7 +1512,7 @@ This does not rely on endianness.

    Source:
    @@ -1645,7 +1653,7 @@ This does not rely on endianness.

    Source:
    @@ -1786,7 +1794,7 @@ This does not rely on endianness.

    Source:
    @@ -1973,7 +1981,7 @@ This does not rely on endianness.

    Source:
    @@ -2183,7 +2191,7 @@ This does not rely on endianness.

    Source:
    @@ -2324,7 +2332,7 @@ This does not rely on endianness.

    Source:
    @@ -2513,7 +2521,7 @@ Set the max value to restrict the maximum color used per channel.

    Source:
    @@ -2654,7 +2662,7 @@ Set the max value to restrict the maximum color used per channel.

    Source:
    @@ -2796,7 +2804,7 @@ Set the max value to restrict the maximum color used per channel.

    Source:
    @@ -2940,7 +2948,7 @@ Set the max value to restrict the maximum color used per channel.

    Source:
    @@ -3092,7 +3100,7 @@ Set the max value to restrict the maximum color used per channel.

    -

    An object into which 3 properties will be created: r, g and b. If not provided a new object will be created.

    +

    An object into which 3 properties will be created or set: r, g and b. If not provided a new object will be created.

    @@ -3124,7 +3132,7 @@ Set the max value to restrict the maximum color used per channel.

    Source:
    @@ -3265,7 +3273,7 @@ Set the max value to restrict the maximum color used per channel.

    Source:
    @@ -3465,7 +3473,7 @@ Set the max value to restrict the maximum color used per channel.

    Source:
    @@ -3914,7 +3922,7 @@ Based on code by Michael Jackson (https:
    Source:
    @@ -4584,7 +4592,7 @@ Based on code by Michael Jackson (https:
    Source:
    @@ -4840,7 +4848,7 @@ Based on code by Michael Jackson (https:
    Source:
    @@ -5142,7 +5150,7 @@ Based on code by Michael Jackson (https:
    Source:
    @@ -6164,7 +6172,7 @@ If prefix was '#' it will be in the format #RRGGBB otherwise
    Source:
    @@ -6807,7 +6815,7 @@ endian-independent method, use fromRGBA(rgba) and toRGBA(r, g, b, a).

    Source:
    @@ -6853,6 +6861,190 @@ endian-independent method, use fromRGBA(rgba) and toRGBA(r, g, b, a).

    + + + + +
    +

    <static> webToColor(web, out) → {object}

    + + +
    +
    + + +
    +

    Converts a CSS 'web' string into a Phaser Color object.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDescription
    web + + +string + + + + + + + + + +

    The web string in the format: 'rgba(r,g,b,a)'

    out + + +object + + + + + + <optional>
    + + + + + +

    An object into which 3 properties will be created: r, g and b. If not provided a new object will be created.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    An object with the red, green and blue values set in the r, g and b properties.

    +
    + + + +
    +
    + Type +
    +
    + +object + + +
    +
    + + + + +
    @@ -6881,7 +7073,7 @@ endian-independent method, use fromRGBA(rgba) and toRGBA(r, g, b, a).

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:21 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:49 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Device.html b/docs/Phaser.Device.html index af7b49ac5..c92b8a695 100644 --- a/docs/Phaser.Device.html +++ b/docs/Phaser.Device.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -594,7 +602,7 @@
    Source:
    @@ -725,7 +733,7 @@
    Source:
    @@ -830,7 +838,7 @@
    Source:
    @@ -935,7 +943,7 @@
    Source:
    @@ -1037,7 +1045,7 @@
    Source:
    @@ -1142,7 +1150,7 @@
    Source:
    @@ -1247,7 +1255,7 @@
    Source:
    @@ -1352,7 +1360,7 @@
    Source:
    @@ -1457,7 +1465,7 @@
    Source:
    @@ -1562,7 +1570,7 @@
    Source:
    @@ -1667,7 +1675,7 @@
    Source:
    @@ -1772,7 +1780,7 @@
    Source:
    @@ -1877,7 +1885,7 @@
    Source:
    @@ -1982,7 +1990,7 @@
    Source:
    @@ -2087,7 +2095,7 @@
    Source:
    @@ -2192,7 +2200,7 @@
    Source:
    @@ -2297,7 +2305,7 @@
    Source:
    @@ -2402,7 +2410,7 @@
    Source:
    @@ -2507,7 +2515,7 @@
    Source:
    @@ -2612,7 +2620,7 @@
    Source:
    @@ -2717,7 +2725,7 @@
    Source:
    @@ -2819,7 +2827,7 @@
    Source:
    @@ -2924,7 +2932,7 @@
    Source:
    @@ -3029,7 +3037,7 @@
    Source:
    @@ -3134,7 +3142,7 @@
    Source:
    @@ -3239,7 +3247,7 @@
    Source:
    @@ -3344,7 +3352,7 @@
    Source:
    @@ -3449,7 +3457,7 @@
    Source:
    @@ -3554,7 +3562,7 @@
    Source:
    @@ -3659,7 +3667,7 @@
    Source:
    @@ -3764,7 +3772,7 @@
    Source:
    @@ -3869,7 +3877,7 @@
    Source:
    @@ -3978,7 +3986,7 @@
    Source:
    @@ -4083,7 +4091,7 @@
    Source:
    @@ -4188,7 +4196,7 @@
    Source:
    @@ -4293,7 +4301,7 @@
    Source:
    @@ -4398,7 +4406,7 @@
    Source:
    @@ -4503,7 +4511,7 @@
    Source:
    @@ -4608,7 +4616,7 @@
    Source:
    @@ -4713,7 +4721,7 @@
    Source:
    @@ -4818,7 +4826,7 @@
    Source:
    @@ -4923,7 +4931,7 @@
    Source:
    @@ -5028,7 +5036,7 @@
    Source:
    @@ -5133,7 +5141,7 @@
    Source:
    @@ -5238,7 +5246,7 @@
    Source:
    @@ -5343,7 +5351,7 @@
    Source:
    @@ -5445,7 +5453,7 @@
    Source:
    @@ -5550,7 +5558,7 @@
    Source:
    @@ -5655,7 +5663,7 @@
    Source:
    @@ -5760,7 +5768,7 @@
    Source:
    @@ -5865,7 +5873,7 @@
    Source:
    @@ -5970,7 +5978,7 @@
    Source:
    @@ -6075,7 +6083,7 @@
    Source:
    @@ -6180,7 +6188,7 @@
    Source:
    @@ -6285,7 +6293,7 @@
    Source:
    @@ -6390,7 +6398,7 @@
    Source:
    @@ -6495,7 +6503,7 @@
    Source:
    @@ -6600,7 +6608,7 @@
    Source:
    @@ -6705,7 +6713,7 @@
    Source:
    @@ -6810,7 +6818,7 @@
    Source:
    @@ -6915,7 +6923,7 @@
    Source:
    @@ -7020,7 +7028,7 @@
    Source:
    @@ -7125,7 +7133,7 @@
    Source:
    @@ -7239,7 +7247,7 @@
    Source:
    @@ -7331,7 +7339,7 @@
    Source:
    @@ -7402,7 +7410,7 @@ Usage: var defaultRenderingMode = Phaser.Device.isAndroidStockBrowser() ? Phaser
    Source:
    @@ -7473,7 +7481,7 @@ It used to work in Chrome, but then they removed the ability: Source:
    @@ -7547,7 +7555,7 @@ It used to work in Chrome, but then they removed the ability: Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:22 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:49 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Back.html b/docs/Phaser.Easing.Back.html index 37f99612a..4225511f9 100644 --- a/docs/Phaser.Easing.Back.html +++ b/docs/Phaser.Easing.Back.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1084,7 +1092,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:22 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:50 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Bounce.html b/docs/Phaser.Easing.Bounce.html index 346bd2ac6..69e6e1ddc 100644 --- a/docs/Phaser.Easing.Bounce.html +++ b/docs/Phaser.Easing.Bounce.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1084,7 +1092,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:22 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:50 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Circular.html b/docs/Phaser.Easing.Circular.html index 05fcb803a..5d0993f21 100644 --- a/docs/Phaser.Easing.Circular.html +++ b/docs/Phaser.Easing.Circular.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1084,7 +1092,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:23 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:50 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Cubic.html b/docs/Phaser.Easing.Cubic.html index 59afb0876..1b53a47ec 100644 --- a/docs/Phaser.Easing.Cubic.html +++ b/docs/Phaser.Easing.Cubic.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1084,7 +1092,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:23 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:50 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Elastic.html b/docs/Phaser.Easing.Elastic.html index 69799d24c..3a5db86fc 100644 --- a/docs/Phaser.Easing.Elastic.html +++ b/docs/Phaser.Easing.Elastic.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1084,7 +1092,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:23 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:50 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Exponential.html b/docs/Phaser.Easing.Exponential.html index 2bfe9d48b..9d2e775d1 100644 --- a/docs/Phaser.Easing.Exponential.html +++ b/docs/Phaser.Easing.Exponential.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1084,7 +1092,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:23 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:51 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Linear.html b/docs/Phaser.Easing.Linear.html index 7ca4fc41f..e4cd63622 100644 --- a/docs/Phaser.Easing.Linear.html +++ b/docs/Phaser.Easing.Linear.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -802,7 +810,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:23 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:51 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Quadratic.html b/docs/Phaser.Easing.Quadratic.html index a5bc3357e..928716aff 100644 --- a/docs/Phaser.Easing.Quadratic.html +++ b/docs/Phaser.Easing.Quadratic.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1084,7 +1092,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:23 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:51 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Quartic.html b/docs/Phaser.Easing.Quartic.html index 1397930e9..7acef2947 100644 --- a/docs/Phaser.Easing.Quartic.html +++ b/docs/Phaser.Easing.Quartic.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1084,7 +1092,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:23 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:51 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Quintic.html b/docs/Phaser.Easing.Quintic.html index 91055b305..a4b105007 100644 --- a/docs/Phaser.Easing.Quintic.html +++ b/docs/Phaser.Easing.Quintic.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1084,7 +1092,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:24 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:51 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.Sinusoidal.html b/docs/Phaser.Easing.Sinusoidal.html index 561ba409f..ebe195a4a 100644 --- a/docs/Phaser.Easing.Sinusoidal.html +++ b/docs/Phaser.Easing.Sinusoidal.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1084,7 +1092,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:24 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:51 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Easing.html b/docs/Phaser.Easing.html index 945f028f3..917daf873 100644 --- a/docs/Phaser.Easing.html +++ b/docs/Phaser.Easing.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -751,7 +759,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:22 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:50 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Ellipse.html b/docs/Phaser.Ellipse.html index a21f51de5..a6dfb6985 100644 --- a/docs/Phaser.Ellipse.html +++ b/docs/Phaser.Ellipse.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Ellipse -

    Phaser - Ellipse

    +

    Phaser.Ellipse

    @@ -553,7 +561,7 @@
    -

    new Ellipse(x, y, width, height) → {Phaser.Ellipse}

    +

    new Ellipse(x, y, width, height)

    @@ -780,7 +788,7 @@
    Source:
    @@ -801,29 +809,6 @@ -
    Returns:
    - - -
    -

    This Ellipse object

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Ellipse - - -
    -
    - - - @@ -935,7 +920,7 @@
    Source:
    @@ -1042,7 +1027,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -1144,7 +1129,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -1198,7 +1183,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -1304,7 +1289,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -1410,7 +1395,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -1512,7 +1497,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -1614,7 +1599,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -1716,7 +1701,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -1876,7 +1861,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -1968,7 +1953,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -2109,7 +2094,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -2273,7 +2258,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -2414,7 +2399,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -2473,7 +2458,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    -

    Copies the x, y and diameter properties from this Circle to any given object.

    +

    Copies the x, y, width and height properties from this Ellipse to any given object.

    @@ -2555,7 +2540,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -2765,7 +2750,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -2857,7 +2842,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli
    Source:
    @@ -2931,7 +2916,7 @@ If set to true it will reset all of the Ellipse objects properties to 0. An Elli Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:24 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:52 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Events.html b/docs/Phaser.Events.html index 1830ceeeb..e4db1ba07 100644 --- a/docs/Phaser.Events.html +++ b/docs/Phaser.Events.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,11 +550,7 @@ Events -

    The Events component is a collection of events fired by the parent game object.

    -

    For example to tell when a Sprite has been added to a new group:

    -

    sprite.events.onAddedToGroup.add(yourFunction, this);

    -

    Where yourFunction is the function you want called when this event occurs.

    -

    Note that the Input related events only exist if the Sprite has had inputEnabled set to true.

    +

    Phaser.Events

    @@ -564,6 +568,14 @@
    +
    +

    The Events component is a collection of events fired by the parent game object.

    +

    For example to tell when a Sprite has been added to a new group:

    +

    sprite.events.onAddedToGroup.add(yourFunction, this);

    +

    Where yourFunction is the function you want called when this event occurs.

    +

    Note that the Input related events only exist if the Sprite has had inputEnabled set to true.

    +
    + @@ -643,7 +655,7 @@
    Source:
    @@ -771,7 +783,7 @@
    Source:
    @@ -876,7 +888,7 @@
    Source:
    @@ -981,7 +993,7 @@
    Source:
    @@ -1086,7 +1098,7 @@
    Source:
    @@ -1188,7 +1200,7 @@
    Source:
    @@ -1293,7 +1305,7 @@
    Source:
    @@ -1398,7 +1410,7 @@
    Source:
    @@ -1500,7 +1512,7 @@
    Source:
    @@ -1605,7 +1617,7 @@
    Source:
    @@ -1710,7 +1722,7 @@
    Source:
    @@ -1815,7 +1827,7 @@
    Source:
    @@ -1920,7 +1932,7 @@
    Source:
    @@ -2022,7 +2034,7 @@
    Source:
    @@ -2124,7 +2136,7 @@
    Source:
    @@ -2226,7 +2238,7 @@
    Source:
    @@ -2328,7 +2340,7 @@
    Source:
    @@ -2430,7 +2442,7 @@
    Source:
    @@ -2473,7 +2485,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:24 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:52 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Filter.html b/docs/Phaser.Filter.html index 18313b6f4..c9456bce3 100644 --- a/docs/Phaser.Filter.html +++ b/docs/Phaser.Filter.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Filter -

    Phaser - Filter

    +

    Phaser.Filter

    @@ -689,7 +697,7 @@
    Source:
    @@ -820,7 +828,7 @@
    Source:
    @@ -922,7 +930,7 @@
    Source:
    @@ -1024,7 +1032,7 @@
    Source:
    @@ -1126,7 +1134,7 @@
    Source:
    @@ -1231,7 +1239,7 @@
    Source:
    @@ -1333,7 +1341,7 @@
    Source:
    @@ -1435,7 +1443,7 @@
    Source:
    @@ -1537,7 +1545,7 @@
    Source:
    @@ -1602,7 +1610,7 @@
    Source:
    @@ -1671,7 +1679,7 @@
    Source:
    @@ -1812,7 +1820,7 @@
    Source:
    @@ -1942,7 +1950,7 @@
    Source:
    @@ -1993,7 +2001,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:24 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:52 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.FlexGrid.html b/docs/Phaser.FlexGrid.html index 40564597b..f20e08a95 100644 --- a/docs/Phaser.FlexGrid.html +++ b/docs/Phaser.FlexGrid.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -941,7 +949,7 @@ to provide for game object positioning in a responsive manner.

    -

    <readonly> positionFluid

    +

    <readonly> positionCustom

    @@ -1025,7 +1033,7 @@ to provide for game object positioning in a responsive manner.

    Source:
    @@ -1043,7 +1051,7 @@ to provide for game object positioning in a responsive manner.

    -

    <readonly> scaleFluid

    +

    <readonly> scaleCustom

    @@ -1127,7 +1135,7 @@ to provide for game object positioning in a responsive manner.

    Source:
    @@ -1170,7 +1178,7 @@ to provide for game object positioning in a responsive manner.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:24 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:52 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.FlexLayer.html b/docs/Phaser.FlexLayer.html index 6c8148123..71b401c1e 100644 --- a/docs/Phaser.FlexLayer.html +++ b/docs/Phaser.FlexLayer.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -857,7 +865,7 @@ This is also why the documentation is incomplete.

    Source:
    @@ -964,7 +972,7 @@ This is also why the documentation is incomplete.

    Source:
    @@ -1076,7 +1084,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1183,7 +1191,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1295,7 +1303,7 @@ When a new object is created it is passed the following parameters to its constr
    Source:
    @@ -1407,7 +1415,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1517,7 +1525,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1624,7 +1632,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1734,7 +1742,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1847,7 +1855,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -1954,7 +1962,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2065,6 +2073,116 @@ So if this Group was in a Group that has x: 200, then this will be added to the + + + + + + + + +
    +

    ignoreDestroy

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    ignoreDestroy + + +boolean + + + +

    A Group with ignoreDestroy set to true ignores all calls to its destroy method.

    +
    + + + + + + + + +
    Inherited From:
    +
    + + + + + + + + + + + +
    Default Value:
    +
    • false
    + + + +
    Source:
    +
    + + + + + + +
    @@ -2163,7 +2281,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2372,7 +2490,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2479,7 +2597,71 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    + + + + + + + + + + + + + + + +
    +

    persist :boolean

    + + +
    +
    + +
    +

    Should the FlexLayer remain through a State swap?

    +
    + + + +
    Type:
    +
      +
    • + +boolean + + +
    • +
    + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -2586,7 +2768,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2698,7 +2880,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2805,7 +2987,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2912,7 +3094,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3019,7 +3201,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3126,7 +3308,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3238,7 +3420,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3350,7 +3532,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3457,7 +3639,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3633,7 +3815,7 @@ that then see the addAt method.

    Source:
    @@ -3858,7 +4040,7 @@ Group.addAll('x', 10) will add 10 to the child.x value.

    Source:
    @@ -4072,7 +4254,7 @@ The child is added to the Group at the location specified by the index value, th
    Source:
    @@ -4275,7 +4457,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4444,7 +4626,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4567,7 +4749,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4806,7 +4988,7 @@ After the method parameter and context you can add as many extra parameters as y
    Source:
    @@ -5004,7 +5186,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -5173,7 +5355,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -5465,7 +5647,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5713,7 +5895,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5810,7 +5992,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5907,7 +6089,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -6219,7 +6401,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -6501,7 +6683,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -6648,7 +6830,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -6794,7 +6976,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -6976,7 +7158,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -7169,7 +7351,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7192,6 +7374,213 @@ Group.divideAll('x', 2) will half the child.x value.

    +
    + + + +
    +

    filter(predicate, checkExists) → {Phaser.ArrayList}

    + + +
    +
    + + +
    +

    Allows you to obtain a Phaser.ArrayList of children that return true for the given predicate +For example: + var healthyList = Group.filter(function(child, index, children) { + return child.health > 10 ? true : false; + }, true); + healthyList.callAll('attack'); +Note: Currently this will skip any children which are Groups themselves.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    predicate + + +function + + + + + + + + + + + +

    The function that each child will be evaluated against. Each child of the Group will be passed to it as its first parameter, the index as the second, and the entire child array as the third

    checkExists + + +boolean + + + + + + <optional>
    + + + + + +
    + + false + +

    If set only children with exists=true will be passed to the callback, otherwise all children will be passed.

    + + + + +
    + + + + + + + +
    Inherited From:
    +
    + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    Returns an array list containing all the children that the predicate returned true for

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.ArrayList + + +
    +
    + + + + +
    @@ -7385,7 +7774,7 @@ Note: Currently this will skip any children which are Groups themselves.

    Source:
    @@ -7533,7 +7922,7 @@ For example: Group.forEachAlive(causeDamage, this, 500)

    Source:
    @@ -7681,7 +8070,7 @@ For example: Group.forEachDead(bringToLife, this)

    Source:
    @@ -7829,7 +8218,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -7952,7 +8341,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -8049,7 +8438,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -8147,7 +8536,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8245,7 +8634,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8391,7 +8780,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8537,7 +8926,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8706,7 +9095,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8803,7 +9192,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8972,7 +9361,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9282,7 +9671,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -9428,7 +9817,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -9574,7 +9963,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -9790,7 +10179,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -9864,7 +10253,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -9961,7 +10350,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10035,7 +10424,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10109,7 +10498,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10350,7 +10739,7 @@ reset the Group cursor and optionally destroy the child.

    Source:
    @@ -10556,7 +10945,7 @@ The Group container remains on the display list.

    Source:
    @@ -10810,7 +11199,7 @@ The Group container remains on the display list.

    Source:
    @@ -10956,7 +11345,7 @@ The Group container remains on the display list.

    Source:
    @@ -11122,7 +11511,7 @@ The Group container remains on the display list.

    Source:
    @@ -11219,7 +11608,7 @@ The Group container remains on the display list.

    Source:
    @@ -11342,7 +11731,7 @@ The Group container remains on the display list.

    Source:
    @@ -11731,7 +12120,7 @@ The operation parameter controls how the new value is assigned to the property,
    Source:
    @@ -12087,7 +12476,7 @@ If you need that ability please see Group.setAllChildren.

    Source:
    @@ -12420,7 +12809,7 @@ Unlike with Group.setAll the property is NOT set on child Groups itself.

    Source:
    @@ -12712,7 +13101,7 @@ Operation 0 means set the existing value to the given value, or if force is Source:
    @@ -12918,7 +13307,7 @@ For example to depth sort Sprites for Zelda-style game you might call grou
    Source:
    @@ -13111,7 +13500,7 @@ Group.subAll('x', 10) will minus 10 from the child.x value.

    Source:
    @@ -13258,7 +13647,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13332,7 +13721,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13406,7 +13795,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13575,7 +13964,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13626,7 +14015,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:25 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:52 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Frame.html b/docs/Phaser.Frame.html index 3fe8425d9..254f2bc70 100644 --- a/docs/Phaser.Frame.html +++ b/docs/Phaser.Frame.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -3426,7 +3434,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:25 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:53 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.FrameData.html b/docs/Phaser.FrameData.html index 715e678a4..94fea7cd9 100644 --- a/docs/Phaser.FrameData.html +++ b/docs/Phaser.FrameData.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -2016,7 +2024,7 @@ The frames are returned in the output array, or if none is provided in a new Arr Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:25 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:53 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Game.html b/docs/Phaser.Game.html index f4b9a1343..7c9bf25ef 100644 --- a/docs/Phaser.Game.html +++ b/docs/Phaser.Game.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,10 +550,7 @@ Game -

    This is where the magic happens. The Game object is the heart of your game, -providing quick access to common functions and handling the boot process. -"Hell, there are no rules here - we're trying to accomplish something." - Thomas A. Edison

    +

    Phaser.Game

    @@ -564,8 +569,10 @@ providing quick access to common functions and handling the boot process.
    -

    Game constructor

    -

    Instantiate a new <code>Phaser.Game</code> object.

    +

    This is where the magic happens. The Game object is the heart of your game, +providing quick access to common functions and handling the boot process. +"Hell, there are no rules here - we're trying to accomplish something." + Thomas A. Edison

    @@ -949,7 +956,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -1077,7 +1084,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -1182,7 +1189,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -1284,7 +1291,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -1386,7 +1393,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -1488,7 +1495,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -1590,7 +1597,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -1692,7 +1699,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -1794,7 +1801,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -1896,7 +1903,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -2001,7 +2008,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -2103,7 +2110,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -2205,7 +2212,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -2310,7 +2317,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -2415,7 +2422,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -2517,7 +2524,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -2619,7 +2626,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -2721,7 +2728,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -2823,7 +2830,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -2925,7 +2932,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -3027,7 +3034,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -3129,7 +3136,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -3231,7 +3238,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -3336,7 +3343,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -3438,7 +3445,7 @@ providing quick access to common functions and handling the boot process.
    Source:
    @@ -3545,7 +3552,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -3650,7 +3657,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -3752,7 +3759,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -3854,7 +3861,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -3959,7 +3966,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -4061,7 +4068,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -4166,7 +4173,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -4268,7 +4275,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -4370,7 +4377,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -4472,7 +4479,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -4574,7 +4581,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -4676,7 +4683,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -4778,7 +4785,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -4883,7 +4890,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -4988,7 +4995,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -5090,7 +5097,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -5195,7 +5202,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -5297,7 +5304,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -5402,7 +5409,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -5504,7 +5511,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -5569,7 +5576,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -5638,7 +5645,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -5707,7 +5714,7 @@ When a game is paused the onPause event is dispatched. When it is resumed the on
    Source:
    @@ -5777,7 +5784,7 @@ Calling step will advance the game loop by one frame. This is extremely useful f
    Source:
    @@ -5895,7 +5902,7 @@ Calling step will advance the game loop by one frame. This is extremely useful f
    Source:
    @@ -6013,7 +6020,7 @@ Calling step will advance the game loop by one frame. This is extremely useful f
    Source:
    @@ -6131,7 +6138,7 @@ Calling step will advance the game loop by one frame. This is extremely useful f
    Source:
    @@ -6249,7 +6256,7 @@ Calling step will advance the game loop by one frame. This is extremely useful f
    Source:
    @@ -6318,7 +6325,7 @@ Calling step will advance the game loop by one frame. This is extremely useful f
    Source:
    @@ -6387,7 +6394,7 @@ Calling step will advance the game loop by one frame. This is extremely useful f
    Source:
    @@ -6456,7 +6463,7 @@ Calling step will advance the game loop by one frame. This is extremely useful f
    Source:
    @@ -6526,7 +6533,7 @@ This is extremely useful to hard to track down errors! Use the internal stepCoun
    Source:
    @@ -6644,7 +6651,7 @@ This is extremely useful to hard to track down errors! Use the internal stepCoun
    Source:
    @@ -6695,7 +6702,7 @@ This is extremely useful to hard to track down errors! Use the internal stepCoun Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:25 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:53 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.GameObjectCreator.html b/docs/Phaser.GameObjectCreator.html index 551b0b294..6a87fe7d1 100644 --- a/docs/Phaser.GameObjectCreator.html +++ b/docs/Phaser.GameObjectCreator.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1167,6 +1175,147 @@ Use the GameObjectFactory to create and add the objects into the world.

    + + + + +
    +

    audioSprite(key) → {Phaser.AudioSprite}

    + + +
    +
    + + +
    +

    Creates a new AudioSprite object.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    key + + +string + + + +

    The Game.cache key of the sound that this object will use.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    The newly created AudioSprite object.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.AudioSprite + + +
    +
    + + + + +
    @@ -1399,7 +1548,7 @@ Use the GameObjectFactory to create and add the objects into the world.

    Source:
    @@ -1678,7 +1827,7 @@ Use the GameObjectFactory to create and add the objects into the world.

    Source:
    @@ -2107,7 +2256,7 @@ Use the GameObjectFactory to create and add the objects into the world.

    Source:
    @@ -2348,7 +2497,7 @@ at set intervals, and fixes their positions and velocities accorindgly.

    Source:
    @@ -2512,7 +2661,7 @@ at set intervals, and fixes their positions and velocities accorindgly.

    Source:
    @@ -2676,7 +2825,7 @@ at set intervals, and fixes their positions and velocities accorindgly.

    Source:
    @@ -3523,7 +3672,7 @@ It can still rotate, scale, crop and receive input events. This makes it perfect
    Source:
    @@ -3981,7 +4130,7 @@ i.e. if you need each Image to have different text in it, then you need to creat
    Source:
    @@ -4249,7 +4398,7 @@ i.e. if you need each Image to have different text in it, then you need to creat
    Source:
    @@ -4523,7 +4672,7 @@ i.e. if you need each Image to have different text in it, then you need to creat
    Source:
    @@ -5223,7 +5372,7 @@ i.e. if you need each Image to have different text in it, then you need to creat
    Source:
    @@ -5542,7 +5691,7 @@ Note that all Tilemaps use a base tile size to calculate dimensions from, but th
    Source:
    @@ -5787,7 +5936,7 @@ Note that all Tilemaps use a base tile size to calculate dimensions from, but th
    Source:
    @@ -6002,7 +6151,7 @@ Note that all Tilemaps use a base tile size to calculate dimensions from, but th Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:26 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:53 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.GameObjectFactory.html b/docs/Phaser.GameObjectFactory.html index dbf67a1c9..1d8cdca10 100644 --- a/docs/Phaser.GameObjectFactory.html +++ b/docs/Phaser.GameObjectFactory.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1166,6 +1174,147 @@ + + + + +
    +

    audioSprite(key) → {Phaser.AudioSprite}

    + + +
    +
    + + +
    +

    Creates a new AudioSprite object.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    key + + +string + + + +

    The Game.cache key of the sound that this object will use.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    The newly created AudioSprite object.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.AudioSprite + + +
    +
    + + + + +
    @@ -1398,7 +1547,7 @@
    Source:
    @@ -1710,7 +1859,7 @@
    Source:
    @@ -2172,7 +2321,7 @@
    Source:
    @@ -2413,7 +2562,7 @@ at set intervals, and fixes their positions and velocities accorindgly.

    Source:
    @@ -2718,7 +2867,7 @@ at set intervals, and fixes their positions and velocities accorindgly.

    Source:
    @@ -2933,7 +3082,7 @@ at set intervals, and fixes their positions and velocities accorindgly.

    Source:
    @@ -4003,7 +4152,7 @@ The Plugin must have 2 properties: game and parent. Plugin.game is set to the ga
    Source:
    @@ -4281,7 +4430,7 @@ The Plugin must have 2 properties: game and parent. Plugin.game is set to the ga
    Source:
    @@ -4739,7 +4888,7 @@ i.e. if you need each Image to have different text in it, then you need to creat
    Source:
    @@ -5090,7 +5239,7 @@ i.e. if you need each Image to have different text in it, then you need to creat
    Source:
    @@ -6169,7 +6318,7 @@ The speed gains are specifically for WebGL. In Canvas mode you won't see any rea
    Source:
    @@ -6488,7 +6637,7 @@ Note that all Tilemaps use a base tile size to calculate dimensions from, but th
    Source:
    @@ -6839,7 +6988,7 @@ Note that all Tilemaps use a base tile size to calculate dimensions from, but th
    Source:
    @@ -7054,7 +7203,7 @@ Note that all Tilemaps use a base tile size to calculate dimensions from, but th Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:26 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:54 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Gamepad.html b/docs/Phaser.Gamepad.html index c2be9141f..1e7344af6 100644 --- a/docs/Phaser.Gamepad.html +++ b/docs/Phaser.Gamepad.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -3409,7 +3417,7 @@ This MUST be called manually before Phaser will start polling the Gamepad API. Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:26 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:54 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.GamepadButton.html b/docs/Phaser.GamepadButton.html index 194b507fd..dda392fab 100644 --- a/docs/Phaser.GamepadButton.html +++ b/docs/Phaser.GamepadButton.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ GamepadButton -

    If you need more fine-grained control over the handling of specific buttons you can create and use Phaser.GamepadButton objects.

    +

    Phaser.GamepadButton

    @@ -560,6 +568,10 @@
    +
    +

    If you need more fine-grained control over the handling of specific buttons you can create and use Phaser.GamepadButton objects.

    +
    + @@ -662,7 +674,7 @@
    Source:
    @@ -790,7 +802,7 @@
    Source:
    @@ -900,7 +912,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -1002,7 +1014,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -1107,7 +1119,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -1212,7 +1224,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -1314,7 +1326,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -1416,7 +1428,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -1518,7 +1530,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -1620,7 +1632,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -1725,7 +1737,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -1830,7 +1842,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -1935,7 +1947,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -2040,7 +2052,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -2105,7 +2117,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -2243,7 +2255,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -2404,7 +2416,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -2545,7 +2557,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -2663,7 +2675,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -2781,7 +2793,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -2850,7 +2862,7 @@ If the button is up it holds the duration of the previous down session.

    Source:
    @@ -2901,7 +2913,7 @@ If the button is up it holds the duration of the previous down session.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:26 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:54 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Graphics.html b/docs/Phaser.Graphics.html index ac3885be4..0f4e7f1ab 100644 --- a/docs/Phaser.Graphics.html +++ b/docs/Phaser.Graphics.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -718,6 +726,12 @@ +

    Extends

    + +
      +
    • PIXI.Graphics
    • +
    + @@ -2598,7 +2612,7 @@ Draws {Phaser.Polygon} triangles

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:26 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:54 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Group.html b/docs/Phaser.Group.html index 6366b0904..38b1ab744 100644 --- a/docs/Phaser.Group.html +++ b/docs/Phaser.Group.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Group -

    A Group is a container for display objects that allows for fast pooling and object recycling. Groups can be nested within other Groups and have their own local transforms.

    +

    Phaser.Group

    @@ -561,7 +569,8 @@
    -

    Phaser Group constructor.

    +

    A Group is a container for display objects that allows for fast pooling and object recycling. +Groups can be nested within other Groups and have their own local transforms.

    @@ -856,7 +865,7 @@
    Source:
    @@ -942,7 +951,7 @@
    Source:
    @@ -1002,7 +1011,7 @@
    Source:
    @@ -1062,7 +1071,7 @@
    Source:
    @@ -1122,7 +1131,7 @@
    Source:
    @@ -1182,7 +1191,7 @@
    Source:
    @@ -1287,7 +1296,7 @@
    Source:
    @@ -1389,7 +1398,7 @@
    Source:
    @@ -1496,7 +1505,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1598,7 +1607,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1705,7 +1714,7 @@ When a new object is created it is passed the following parameters to its constr
    Source:
    @@ -1812,7 +1821,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1917,7 +1926,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -2019,7 +2028,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -2124,7 +2133,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -2232,7 +2241,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2334,7 +2343,112 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    + + + + + + + + + + + + + + + +
    +

    ignoreDestroy

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    ignoreDestroy + + +boolean + + + +

    A Group with ignoreDestroy set to true ignores all calls to its destroy method.

    +
    + + + + + + + + + + + + + + + + + + +
    Default Value:
    +
    • false
    + + + +
    Source:
    +
    @@ -2436,7 +2550,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2538,7 +2652,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2640,7 +2754,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2742,7 +2856,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2849,7 +2963,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2951,7 +3065,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3053,7 +3167,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3155,7 +3269,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3257,7 +3371,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3364,7 +3478,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3471,7 +3585,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3573,7 +3687,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3744,7 +3858,7 @@ that then see the addAt method.

    Source:
    @@ -3964,7 +4078,7 @@ Group.addAll('x', 10) will add 10 to the child.x value.

    Source:
    @@ -4173,7 +4287,7 @@ The child is added to the Group at the location specified by the index value, th
    Source:
    @@ -4371,7 +4485,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4535,7 +4649,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4653,7 +4767,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4887,7 +5001,7 @@ After the method parameter and context you can add as many extra parameters as y
    Source:
    @@ -5080,7 +5194,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -5244,7 +5358,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -5531,7 +5645,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5774,7 +5888,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5866,7 +5980,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5958,7 +6072,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -6265,7 +6379,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -6542,7 +6656,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -6684,7 +6798,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -6825,7 +6939,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -7002,7 +7116,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -7190,7 +7304,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7213,6 +7327,208 @@ Group.divideAll('x', 2) will half the child.x value.

    +
    + + + +
    +

    filter(predicate, checkExists) → {Phaser.ArrayList}

    + + +
    +
    + + +
    +

    Allows you to obtain a Phaser.ArrayList of children that return true for the given predicate +For example: + var healthyList = Group.filter(function(child, index, children) { + return child.health > 10 ? true : false; + }, true); + healthyList.callAll('attack'); +Note: Currently this will skip any children which are Groups themselves.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    predicate + + +function + + + + + + + + + + + +

    The function that each child will be evaluated against. Each child of the Group will be passed to it as its first parameter, the index as the second, and the entire child array as the third

    checkExists + + +boolean + + + + + + <optional>
    + + + + + +
    + + false + +

    If set only children with exists=true will be passed to the callback, otherwise all children will be passed.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    Returns an array list containing all the children that the predicate returned true for

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.ArrayList + + +
    +
    + + + + +
    @@ -7401,7 +7717,7 @@ Note: Currently this will skip any children which are Groups themselves.

    Source:
    @@ -7544,7 +7860,7 @@ For example: Group.forEachAlive(causeDamage, this, 500)

    Source:
    @@ -7687,7 +8003,7 @@ For example: Group.forEachDead(bringToLife, this)

    Source:
    @@ -7830,7 +8146,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -7948,7 +8264,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -8040,7 +8356,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -8133,7 +8449,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8226,7 +8542,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8367,7 +8683,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8508,7 +8824,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8672,7 +8988,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8764,7 +9080,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8928,7 +9244,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9233,7 +9549,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -9374,7 +9690,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -9515,7 +9831,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -9726,7 +10042,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -9795,7 +10111,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -9887,7 +10203,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -9956,7 +10272,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10025,7 +10341,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10261,7 +10577,7 @@ reset the Group cursor and optionally destroy the child.

    Source:
    @@ -10462,7 +10778,7 @@ The Group container remains on the display list.

    Source:
    @@ -10711,7 +11027,7 @@ The Group container remains on the display list.

    Source:
    @@ -10852,7 +11168,7 @@ The Group container remains on the display list.

    Source:
    @@ -11013,7 +11329,7 @@ The Group container remains on the display list.

    Source:
    @@ -11105,7 +11421,7 @@ The Group container remains on the display list.

    Source:
    @@ -11223,7 +11539,7 @@ The Group container remains on the display list.

    Source:
    @@ -11607,7 +11923,7 @@ The operation parameter controls how the new value is assigned to the property,
    Source:
    @@ -11958,7 +12274,7 @@ If you need that ability please see Group.setAllChildren.

    Source:
    @@ -12286,7 +12602,7 @@ Unlike with Group.setAll the property is NOT set on child Groups itself.

    Source:
    @@ -12573,7 +12889,7 @@ Operation 0 means set the existing value to the given value, or if force is Source:
    @@ -12774,7 +13090,7 @@ For example to depth sort Sprites for Zelda-style game you might call grou
    Source:
    @@ -12962,7 +13278,7 @@ Group.subAll('x', 10) will minus 10 from the child.x value.

    Source:
    @@ -13104,7 +13420,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13173,7 +13489,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13242,7 +13558,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13406,7 +13722,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13457,7 +13773,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:27 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:54 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Image.html b/docs/Phaser.Image.html index 7d9d251aa..0e2f54c4b 100644 --- a/docs/Phaser.Image.html +++ b/docs/Phaser.Image.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,8 +550,7 @@ Image -

    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.

    +

    Phaser.Image

    @@ -561,6 +568,11 @@ It can still rotate, scale, crop and receive input events. This makes it perfect
    +
    +

    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.

    +
    + @@ -773,6 +785,12 @@ It can still rotate, scale, crop and receive input events. This makes it perfect +

    Extends

    + +
      +
    • PIXI.Sprite
    • +
    + @@ -983,7 +1001,7 @@ If you wish to work in radians instead of degrees use the property Image.rotatio
    Source:
    @@ -1614,7 +1632,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -1720,7 +1738,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -1826,7 +1844,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -1928,7 +1946,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -2243,7 +2261,7 @@ So if this Image was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2345,7 +2363,7 @@ So if this Image was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2447,7 +2465,7 @@ So if this Image was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2655,7 +2673,7 @@ So if this Image was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2867,7 +2885,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2973,7 +2991,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3288,7 +3306,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3394,7 +3412,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3766,7 +3784,7 @@ bought to the top of that Group, not the entire display list.

    Source:
    @@ -3966,7 +3984,7 @@ Keep this in mind if assigning a rectangle in a for-loop, or when cleaning up fo
    Source:
    @@ -4105,7 +4123,7 @@ and nulls its reference to game, freeing it up for garbage collection.

    Source:
    @@ -4177,7 +4195,7 @@ If you don't need this Image any more you should call Image.destroy instead.

    Source:
    @@ -4633,7 +4651,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -4725,7 +4743,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -4796,7 +4814,7 @@ It will dispatch the onRevived event, you can listen to Image.events.onRevived f
    Source:
    @@ -4938,7 +4956,7 @@ This is primarily an internal method used by Image.loadTexture, although you may
    Source:
    @@ -5077,7 +5095,7 @@ then you need to update the crop frame by calling this method.

    Source:
    @@ -5128,7 +5146,7 @@ then you need to update the crop frame by calling this method.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:27 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:55 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Input.html b/docs/Phaser.Input.html index 16478edf5..baeedbb7e 100644 --- a/docs/Phaser.Input.html +++ b/docs/Phaser.Input.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -8558,7 +8566,7 @@ directly yourself then set InputManager.resetLocked to true.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:27 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:55 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.InputHandler.html b/docs/Phaser.InputHandler.html index 20925b03a..e2048ab1a 100644 --- a/docs/Phaser.InputHandler.html +++ b/docs/Phaser.InputHandler.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -643,7 +651,7 @@
    Source:
    @@ -774,7 +782,7 @@
    Source:
    @@ -879,7 +887,7 @@
    Source:
    @@ -984,7 +992,7 @@
    Source:
    @@ -1089,7 +1097,7 @@
    Source:
    @@ -1194,7 +1202,7 @@
    Source:
    @@ -1296,7 +1304,7 @@
    Source:
    @@ -1406,7 +1414,7 @@ For example if you had a stack of 6 sprites with the same priority IDs and one c
    Source:
    @@ -1511,7 +1519,7 @@ For example if you had a stack of 6 sprites with the same priority IDs and one c
    Source:
    @@ -1616,7 +1624,7 @@ For example if you had a stack of 6 sprites with the same priority IDs and one c
    Source:
    @@ -1718,7 +1726,7 @@ For example if you had a stack of 6 sprites with the same priority IDs and one c
    Source:
    @@ -1823,7 +1831,7 @@ For example if you had a stack of 6 sprites with the same priority IDs and one c
    Source:
    @@ -1928,7 +1936,7 @@ For example if you had a stack of 6 sprites with the same priority IDs and one c
    Source:
    @@ -2039,7 +2047,7 @@ Warning: This is expensive so only enable if you really need it.

    Source:
    @@ -2150,7 +2158,7 @@ Warning: This is expensive, especially on mobile (where it's not even needed!) s
    Source:
    @@ -2261,7 +2269,109 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    + + + + + + + + + + + + + + + +
    +

    scaleLayer

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    scaleLayer + + +boolean + + + +

    EXPERIMENTAL: Please do not use this property unless you know what it does. Likely to change in the future.

    +
    + + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -2366,7 +2476,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -2471,7 +2581,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -2576,7 +2686,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -2681,7 +2791,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -2786,7 +2896,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -2891,7 +3001,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -2996,7 +3106,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -3098,7 +3208,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -3203,7 +3313,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -3268,7 +3378,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -3337,7 +3447,7 @@ stop this from happening by controlling the priorityID value. The higher the val
    Source:
    @@ -3530,7 +3640,7 @@ It compares the alpha value of the pixel and if >= InputHandler.pixelPerfectA
    Source:
    @@ -3727,7 +3837,7 @@ Use the fastTest flag is to quickly check just the bounding hit are
    Source:
    @@ -3924,7 +4034,7 @@ Use the fastTest flag is to quickly check just the bounding hit are
    Source:
    @@ -4012,7 +4122,7 @@ Use the fastTest flag is to quickly check just the bounding hit are
    Source:
    @@ -4081,7 +4191,7 @@ Use the fastTest flag is to quickly check just the bounding hit are
    Source:
    @@ -4150,7 +4260,7 @@ Use the fastTest flag is to quickly check just the bounding hit are
    Source:
    @@ -4268,7 +4378,7 @@ Use the fastTest flag is to quickly check just the bounding hit are
    Source:
    @@ -4624,7 +4734,7 @@ Use the fastTest flag is to quickly check just the bounding hit are
    Source:
    @@ -4950,7 +5060,243 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    + + + + + + + +
    + + + + + + + + + + + + + +
    + + + +
    +

    globalToLocalX(x)

    + + +
    +
    + + +
    +

    Warning: EXPERIMENTAL

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    x + + +number + + + +
    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + + + +
    + + + +
    +

    globalToLocalY(y)

    + + +
    +
    + + +
    +

    Warning: EXPERIMENTAL

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    y + + +number + + + +
    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -5019,7 +5365,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -5183,7 +5529,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -5343,7 +5689,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -5503,7 +5849,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -5663,7 +6009,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -5800,7 +6146,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -5941,7 +6287,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -6084,7 +6430,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -6237,7 +6583,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -6390,7 +6736,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -6533,7 +6879,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -6670,7 +7016,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -6807,7 +7153,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -6944,7 +7290,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -7081,7 +7427,7 @@ For example 16x16 as the snapX and snapY would make the sprite snap to every 16
    Source:
    @@ -7225,7 +7571,7 @@ This value is only set when the pointer is over this Sprite.

    Source:
    @@ -7367,7 +7713,7 @@ This value is only set when the pointer is over this Sprite.

    Source:
    @@ -7459,7 +7805,7 @@ This value is only set when the pointer is over this Sprite.

    Source:
    @@ -7636,7 +7982,7 @@ This value is only set when the pointer is over this Sprite.

    Source:
    @@ -7777,7 +8123,7 @@ This value is only set when the pointer is over this Sprite.

    Source:
    @@ -7918,7 +8264,7 @@ This value is only set when the pointer is over this Sprite.

    Source:
    @@ -7987,7 +8333,7 @@ This value is only set when the pointer is over this Sprite.

    Source:
    @@ -8105,7 +8451,7 @@ This value is only set when the pointer is over this Sprite.

    Source:
    @@ -8223,7 +8569,7 @@ This value is only set when the pointer is over this Sprite.

    Source:
    @@ -8341,7 +8687,7 @@ This value is only set when the pointer is over this Sprite.

    Source:
    @@ -8569,7 +8915,7 @@ This is called by Phaser.Pointer and shouldn't typically be called directly.

    Source:
    @@ -8643,7 +8989,7 @@ This is called by Phaser.Pointer and shouldn't typically be called directly.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:27 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:55 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Key.html b/docs/Phaser.Key.html index 3ac92126a..6a73f6d43 100644 --- a/docs/Phaser.Key.html +++ b/docs/Phaser.Key.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Key -

    If you need more fine-grained control over the handling of specific keys you can create and use Phaser.Key objects.

    +

    Phaser.Key

    @@ -560,6 +568,10 @@
    +
    +

    If you need more fine-grained control over the handling of specific keys you can create and use Phaser.Key objects.

    +
    + @@ -662,7 +674,7 @@
    Source:
    @@ -793,7 +805,7 @@
    Source:
    @@ -898,7 +910,7 @@
    Source:
    @@ -1008,7 +1020,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -1113,7 +1125,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -1215,7 +1227,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -1317,7 +1329,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -1422,7 +1434,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -1527,7 +1539,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -1629,7 +1641,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -1731,7 +1743,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -1833,7 +1845,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -1935,7 +1947,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -2037,7 +2049,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -2142,7 +2154,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -2247,7 +2259,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -2349,7 +2361,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -2451,7 +2463,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -2585,7 +2597,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -2746,7 +2758,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -2887,7 +2899,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -3005,7 +3017,7 @@ If the key is up it holds the duration of the previous down session.

    Source:
    @@ -3144,7 +3156,7 @@ associated with the onDown and onUp events and nulls the onHoldCallback if set.<
    Source:
    @@ -3195,7 +3207,7 @@ associated with the onDown and onUp events and nulls the onHoldCallback if set.< Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:28 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:56 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Keyboard.html b/docs/Phaser.Keyboard.html index 60c4cb341..0b19ee891 100644 --- a/docs/Phaser.Keyboard.html +++ b/docs/Phaser.Keyboard.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -3974,7 +3982,7 @@ This is called automatically by Phaser.Input and should not normally be invoked Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:28 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:56 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Line.html b/docs/Phaser.Line.html index c8d468b9e..87e87efd9 100644 --- a/docs/Phaser.Line.html +++ b/docs/Phaser.Line.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Line -

    Phaser - Line

    +

    Phaser.Line

    @@ -553,7 +561,7 @@
    -

    new Line(x1, y1, x2, y2) → {Phaser.Line}

    +

    new Line(x1, y1, x2, y2)

    @@ -780,7 +788,7 @@
    Source:
    @@ -801,29 +809,6 @@ -
    Returns:
    - - -
    -

    This line object

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Line - - -
    -
    - - -
    @@ -931,7 +916,7 @@
    Source:
    @@ -1033,7 +1018,7 @@
    Source:
    @@ -1135,7 +1120,7 @@
    Source:
    @@ -1237,7 +1222,7 @@
    Source:
    @@ -1339,7 +1324,7 @@
    Source:
    @@ -1441,7 +1426,7 @@
    Source:
    @@ -1543,7 +1528,7 @@
    Source:
    @@ -1645,7 +1630,7 @@
    Source:
    @@ -1747,7 +1732,7 @@
    Source:
    @@ -1849,7 +1834,7 @@
    Source:
    @@ -1951,7 +1936,7 @@
    Source:
    @@ -2053,7 +2038,7 @@
    Source:
    @@ -2155,7 +2140,7 @@
    Source:
    @@ -2257,7 +2242,7 @@
    Source:
    @@ -2502,7 +2487,7 @@ Adapted from code by Keith Hair

    Source:
    @@ -2843,7 +2828,7 @@ Adapted from code by Keith Hair

    Source:
    @@ -2984,7 +2969,7 @@ Adapted from code by Keith Hair

    Source:
    @@ -3183,7 +3168,7 @@ The start and end points are rounded before this runs as the algorithm works on
    Source:
    @@ -3415,7 +3400,7 @@ Can optionally be calculated from their center coordinates.

    Source:
    @@ -3650,7 +3635,7 @@ Returns the intersection segment of AB and EF as a Point, or null if there is no
    Source:
    @@ -3814,7 +3799,7 @@ Returns the intersection segment of AB and EF as a Point, or null if there is no
    Source:
    @@ -3978,7 +3963,7 @@ Returns the intersection segment of AB and EF as a Point, or null if there is no
    Source:
    @@ -4256,7 +4241,7 @@ Returns the intersection segment of AB and EF as a Point, or null if there is no
    Source:
    @@ -4330,7 +4315,7 @@ Returns the intersection segment of AB and EF as a Point, or null if there is no Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:28 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:56 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.LinkedList.html b/docs/Phaser.LinkedList.html index 1040b71da..e661e0c27 100644 --- a/docs/Phaser.LinkedList.html +++ b/docs/Phaser.LinkedList.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1639,7 +1647,7 @@ The function must exist on the member.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:28 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:56 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Loader.html b/docs/Phaser.Loader.html index 4ba3177ff..d059de39a 100644 --- a/docs/Phaser.Loader.html +++ b/docs/Phaser.Loader.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,8 +550,7 @@ Loader -

    The Loader handles loading all external content such as Images, Sounds, Texture Atlases and data files. -It uses a combination of Image() loading and xhr and provides progress and completion callbacks.

    +

    Phaser.Loader

    @@ -562,8 +569,7 @@ It uses a combination of Image() loading and xhr and provides progress and compl
    -

    Phaser loader constructor. -The Loader handles loading all external content such as Images, Sounds, Texture Atlases and data files. +

    The Loader handles loading all external content such as Images, Sounds, Texture Atlases and data files. It uses a combination of Image() loading and xhr and provides progress and completion callbacks.

    @@ -646,7 +652,7 @@ It uses a combination of Image() loading and xhr and provides progress and compl
    Source:
    @@ -732,7 +738,7 @@ It uses a combination of Image() loading and xhr and provides progress and compl
    Source:
    @@ -792,7 +798,7 @@ It uses a combination of Image() loading and xhr and provides progress and compl
    Source:
    @@ -852,7 +858,7 @@ It uses a combination of Image() loading and xhr and provides progress and compl
    Source:
    @@ -912,7 +918,7 @@ It uses a combination of Image() loading and xhr and provides progress and compl
    Source:
    @@ -972,7 +978,7 @@ It uses a combination of Image() loading and xhr and provides progress and compl
    Source:
    @@ -1080,7 +1086,7 @@ MUST have / on the end of it!

    Source:
    @@ -1188,7 +1194,7 @@ MUST have / on the end of it!

    Source:
    @@ -1290,7 +1296,7 @@ MUST have / on the end of it!

    Source:
    @@ -1395,7 +1401,7 @@ MUST have / on the end of it!

    Source:
    @@ -1500,7 +1506,7 @@ MUST have / on the end of it!

    Source:
    @@ -1602,7 +1608,7 @@ MUST have / on the end of it!

    Source:
    @@ -1704,7 +1710,7 @@ MUST have / on the end of it!

    Source:
    @@ -1806,7 +1812,7 @@ MUST have / on the end of it!

    Source:
    @@ -1908,7 +1914,7 @@ MUST have / on the end of it!

    Source:
    @@ -2010,7 +2016,7 @@ MUST have / on the end of it!

    Source:
    @@ -2112,7 +2118,7 @@ MUST have / on the end of it!

    Source:
    @@ -2220,7 +2226,7 @@ This property is an object containing: sprite, rect, direction, width and height
    Source:
    @@ -2325,7 +2331,7 @@ This property is an object containing: sprite, rect, direction, width and height
    Source:
    @@ -2430,7 +2436,7 @@ This property is an object containing: sprite, rect, direction, width and height
    Source:
    @@ -2532,7 +2538,7 @@ This property is an object containing: sprite, rect, direction, width and height
    Source:
    @@ -2715,7 +2721,7 @@ This property is an object containing: sprite, rect, direction, width and height
    Source:
    @@ -2973,7 +2979,7 @@ This property is an object containing: sprite, rect, direction, width and height
    Source:
    @@ -3221,7 +3227,7 @@ This property is an object containing: sprite, rect, direction, width and height
    Source:
    @@ -3469,7 +3475,7 @@ This property is an object containing: sprite, rect, direction, width and height
    Source:
    @@ -3717,7 +3723,7 @@ This property is an object containing: sprite, rect, direction, width and height
    Source:
    @@ -3907,7 +3913,198 @@ This property is an object containing: sprite, rect, direction, width and height
    Source:
    + + + + + + + + + + + + + + + + + + + +
    Returns:
    + + +
    +

    This Loader instance.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.Loader + + +
    +
    + + + + + + + + + +
    +

    audiosprite(key, urls, atlasURL) → {Phaser.Loader}

    + + +
    +
    + + +
    +

    Add a new audiosprite file to the loader. Audio Sprites are a combination of audio files and a JSON configuration. +The JSON follows the format of that created by https://github.com/tonistiigi/audiosprite

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    key + + +string + + + +

    Unique asset key of the audio file.

    urls + + +Array +| + +string + + + +

    An array containing the URLs of the audio files, i.e.: [ 'audiosprite.mp3', 'audiosprite.ogg', 'audiosprite.m4a' ] or a single string containing just one URL.

    atlasURL + + +string + + + +

    The URL of the audiosprite configuration json.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -4157,7 +4354,7 @@ WARNING: If you specify a callback, the file data will be set to whatever your c
    Source:
    @@ -4501,7 +4698,7 @@ WARNING: If you specify a callback, the file data will be set to whatever your c
    Source:
    @@ -4666,7 +4863,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -4807,7 +5004,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -4925,7 +5122,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -5043,7 +5240,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -5161,7 +5358,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -5302,7 +5499,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -5466,7 +5663,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -5697,7 +5894,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -5928,7 +6125,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -6069,7 +6266,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -6296,7 +6493,7 @@ Use Phaser.Cache to access loaded assets, e.g. Phaser.Cache#checkImageKey

    Source:
    @@ -6567,7 +6764,7 @@ The data must be in Lime + Corona JSON format. Physics Editor by code'n'web expo
    Source:
    @@ -6659,7 +6856,7 @@ The data must be in Lime + Corona JSON format. Physics Editor by code'n'web expo
    Source:
    @@ -6800,7 +6997,7 @@ The data must be in Lime + Corona JSON format. Physics Editor by code'n'web expo
    Source:
    @@ -6987,7 +7184,7 @@ The data must be in Lime + Corona JSON format. Physics Editor by code'n'web expo
    Source:
    @@ -7056,7 +7253,7 @@ The data must be in Lime + Corona JSON format. Physics Editor by code'n'web expo
    Source:
    @@ -7282,7 +7479,7 @@ You can also specify a callback. This will be executed as soon as the script tag
    Source:
    @@ -7483,7 +7680,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible
    Source:
    @@ -7839,7 +8036,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible
    Source:
    @@ -7931,7 +8128,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible
    Source:
    @@ -8139,7 +8336,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible
    Source:
    @@ -8409,7 +8606,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible
    Source:
    @@ -8501,7 +8698,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible
    Source:
    @@ -8593,7 +8790,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible
    Source:
    @@ -8685,7 +8882,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible
    Source:
    @@ -8777,7 +8974,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible
    Source:
    @@ -8823,6 +9020,237 @@ This allows you to easily make loading bars for games. Note that Sprite.visible +
    + + + +
    +

    xml(key, url, overwrite) → {Phaser.Loader}

    + + +
    +
    + + +
    +

    Add an XML file to the Loader.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    key + + +string + + + + + + + + + + + +

    Unique asset key of the xml file.

    url + + +string + + + + + + + + + + + +

    URL of the xml file.

    overwrite + + +boolean + + + + + + <optional>
    + + + + + +
    + + false + +

    If an unloaded file with a matching key already exists in the queue, this entry will overwrite it.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    This Loader instance.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.Loader + + +
    +
    + + + + +
    @@ -8918,7 +9346,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible
    Source:
    @@ -8969,7 +9397,7 @@ This allows you to easily make loading bars for games. Note that Sprite.visible Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:29 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:56 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.LoaderParser.html b/docs/Phaser.LoaderParser.html index 1f74eaa7c..771ea416c 100644 --- a/docs/Phaser.LoaderParser.html +++ b/docs/Phaser.LoaderParser.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -943,7 +951,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:29 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:57 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.MSPointer.html b/docs/Phaser.MSPointer.html index 769e9d37b..94dcf0d1b 100644 --- a/docs/Phaser.MSPointer.html +++ b/docs/Phaser.MSPointer.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,9 +550,7 @@ MSPointer -

    The MSPointer class handles touch interactions with the game and the resulting Pointer objects. -It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 apps using JavaScript. -http://msdn.microsoft.com/en-us/library/ie/hh673557(v=vs.85).aspx

    +

    Phaser.MSPointer

    @@ -563,7 +569,9 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a
    -

    Phaser - MSPointer constructor.

    +

    The MSPointer class handles touch interactions with the game and the resulting Pointer objects. +It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 apps using JavaScript. +http://msdn.microsoft.com/en-us/library/ie/hh673557(v=vs.85).aspx

    @@ -645,7 +653,7 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a
    Source:
    @@ -773,7 +781,7 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a
    Source:
    @@ -879,7 +887,7 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a
    Source:
    @@ -981,7 +989,7 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a
    Source:
    @@ -1063,7 +1071,7 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a - +

    The native DOM event.

    @@ -1095,7 +1103,7 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a
    Source:
    @@ -1181,7 +1189,7 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a - +

    The native DOM event.

    @@ -1299,7 +1307,7 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a - +

    The native DOM event.

    @@ -1400,7 +1408,7 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a
    Source:
    @@ -1520,7 +1528,7 @@ It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 a Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:30 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:57 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Math.html b/docs/Phaser.Math.html index c40f5c2f6..9b8651948 100644 --- a/docs/Phaser.Math.html +++ b/docs/Phaser.Math.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -12473,7 +12481,7 @@ max should be larger than min, or the function will return 0.

    -

    True if angle is given in radians.

    +

    Set to true if the angle is given in radians, otherwise degrees is expected.

    @@ -12767,7 +12775,7 @@ Values must be positive integers, and are passed through Math.abs.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:29 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:57 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Mouse.html b/docs/Phaser.Mouse.html index 9910738db..23634a086 100644 --- a/docs/Phaser.Mouse.html +++ b/docs/Phaser.Mouse.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -3944,7 +3952,7 @@ If the browser successfully enters a locked state the event Phaser.Mouse.pointer Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:29 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:57 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Net.html b/docs/Phaser.Net.html index 5553ad80a..d6ecc2b2e 100644 --- a/docs/Phaser.Net.html +++ b/docs/Phaser.Net.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1464,7 +1472,7 @@ Optionally you can redirect to the new url, or just return it as a string.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:30 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:57 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Particle.html b/docs/Phaser.Particle.html index f3495fb3b..86657d899 100644 --- a/docs/Phaser.Particle.html +++ b/docs/Phaser.Particle.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Particle -

    Create a new Particle object. Particles are extended Sprites that are emitted by a particle emitter such as Phaser.Particles.Arcade.Emitter.

    +

    Phaser.Particle

    @@ -560,6 +568,10 @@
    +
    +

    Create a new Particle object. Particles are extended Sprites that are emitted by a particle emitter such as Phaser.Particles.Arcade.Emitter.

    +
    + @@ -743,7 +755,7 @@
    Source:
    @@ -885,7 +897,7 @@
    Source:
    @@ -987,7 +999,7 @@
    Source:
    @@ -1100,7 +1112,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1207,7 +1219,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1309,7 +1321,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1425,7 +1437,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -1527,7 +1539,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -1654,7 +1666,7 @@ If you need a different result then adjust or re-create the Body shape offsets m
    Source:
    @@ -1761,7 +1773,7 @@ If you need a different result then adjust or re-create the Body shape offsets m
    Source:
    @@ -1877,7 +1889,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1987,7 +1999,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2097,7 +2109,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2208,7 +2220,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2319,7 +2331,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2430,7 +2442,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2537,7 +2549,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2644,7 +2656,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2757,7 +2769,7 @@ Setting Sprite.exists to true will re-add the Body to the physics world (if it h
    Source:
    @@ -2870,7 +2882,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2977,7 +2989,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3084,7 +3096,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3191,7 +3203,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3298,7 +3310,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3409,7 +3421,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3519,7 +3531,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3631,7 +3643,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3742,7 +3754,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3858,7 +3870,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3973,7 +3985,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4080,7 +4092,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4190,7 +4202,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4297,7 +4309,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4399,7 +4411,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4506,7 +4518,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4617,7 +4629,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4724,7 +4736,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4831,7 +4843,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4942,7 +4954,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -5053,7 +5065,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -5160,7 +5172,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -5231,7 +5243,7 @@ bought to the top of that Group, not the entire display list.

    Source:
    @@ -5425,7 +5437,7 @@ A reference to the rectangle is stored in Sprite.cropRect unless the copy<
    Source:
    @@ -5549,7 +5561,7 @@ If health is then taken below or is equal to zero Sprite.kill is ca
    Source:
    @@ -5704,7 +5716,7 @@ and nulls its reference to game, freeing it up for garbage collection.

    Source:
    @@ -5781,7 +5793,7 @@ If you don't need this Sprite any more you should call Sprite.destroy instead.Source:
    @@ -6020,7 +6032,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -6089,7 +6101,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -6226,7 +6238,7 @@ Therefore it's relatively expensive to use in large quantities (i.e. with lots o
    Source:
    @@ -6506,7 +6518,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -6603,7 +6615,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -6677,7 +6689,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -6910,7 +6922,7 @@ If the Particle has a physics body that too is reset.

    Source:
    @@ -6995,7 +7007,7 @@ If the Particle has a physics body that too is reset.

    Source:
    @@ -7140,7 +7152,7 @@ It will dispatch the onRevived event, you can listen to Sprite.events.onRevived
    Source:
    @@ -7220,7 +7232,7 @@ It will dispatch the onRevived event, you can listen to Sprite.events.onRevived
    Source:
    @@ -7344,7 +7356,7 @@ This is primarily an internal method used by Sprite.loadTexture, although you ma
    Source:
    @@ -7413,7 +7425,7 @@ This is primarily an internal method used by Sprite.loadTexture, although you ma
    Source:
    @@ -7482,7 +7494,7 @@ This is primarily an internal method used by Sprite.loadTexture, although you ma
    Source:
    @@ -7557,7 +7569,7 @@ then you need to update the crop frame by calling this method.

    Source:
    @@ -7608,7 +7620,7 @@ then you need to update the crop frame by calling this method.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:30 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:58 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Particles.Arcade.Emitter.html b/docs/Phaser.Particles.Arcade.Emitter.html index 1dbd27a72..69c3b2ba1 100644 --- a/docs/Phaser.Particles.Arcade.Emitter.html +++ b/docs/Phaser.Particles.Arcade.Emitter.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -537,12 +545,12 @@

    + Phaser.Particles.Arcade. + Emitter

    -

    Emitter is a lightweight particle emitter that uses Arcade Physics. -It can be used for one-time explosions or for continuous effects like rain and fire. -All it really does is launch Particle objects out at set intervals, and fixes their positions and velocities accorindgly.

    +

    Phaser.Particles.Arcade.Emitter

    @@ -560,6 +568,12 @@ All it really does is launch Particle objects out at set intervals, and fixes th
    +
    +

    Emitter is a lightweight particle emitter that uses Arcade Physics. +It can be used for one-time explosions or for continuous effects like rain and fire. +All it really does is launch Particle objects out at set intervals, and fixes their positions and velocities accordingly.

    +
    + @@ -772,7 +786,7 @@ All it really does is launch Particle objects out at set intervals, and fixes th
    Source:
    @@ -914,7 +928,7 @@ All it really does is launch Particle objects out at set intervals, and fixes th
    Source:
    @@ -1021,7 +1035,7 @@ All it really does is launch Particle objects out at set intervals, and fixes th
    Source:
    @@ -1123,7 +1137,7 @@ All it really does is launch Particle objects out at set intervals, and fixes th
    Source:
    @@ -1235,7 +1249,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1340,7 +1354,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1442,7 +1456,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1544,7 +1558,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1646,7 +1660,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1748,7 +1762,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1850,7 +1864,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1952,7 +1966,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2059,7 +2073,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2171,7 +2185,7 @@ When a new object is created it is passed the following parameters to its constr
    Source:
    @@ -2283,7 +2297,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -2391,7 +2405,7 @@ Emitter.emitX and Emitter.emitY control the emission location relative to the x/
    Source:
    @@ -2499,7 +2513,7 @@ Emitter.emitX and Emitter.emitY control the emission location relative to the x/
    Source:
    @@ -2609,7 +2623,7 @@ Emitter.emitX and Emitter.emitY control the emission location relative to the x/
    Source:
    @@ -2716,7 +2730,7 @@ Emitter.emitX and Emitter.emitY control the emission location relative to the x/
    Source:
    @@ -2826,7 +2840,7 @@ Emitter.emitX and Emitter.emitY control the emission location relative to the x/
    Source:
    @@ -2939,7 +2953,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3044,7 +3058,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3151,7 +3165,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3256,7 +3270,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3358,7 +3372,117 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    + + + + + + + + + + + + + + + +
    +

    ignoreDestroy

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    ignoreDestroy + + +boolean + + + +

    A Group with ignoreDestroy set to true ignores all calls to its destroy method.

    +
    + + + + + + + + +
    Inherited From:
    +
    + + + + + + + + + + + +
    Default Value:
    +
    • false
    + + + +
    Source:
    +
    @@ -3460,7 +3584,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3567,7 +3691,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3672,7 +3796,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3777,7 +3901,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3879,7 +4003,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3984,7 +4108,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -4086,7 +4210,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -4191,7 +4315,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -4296,7 +4420,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -4401,7 +4525,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -4503,7 +4627,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -4605,7 +4729,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -4707,7 +4831,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -4812,7 +4936,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -4919,7 +5043,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -5021,7 +5145,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -5126,7 +5250,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -5228,7 +5352,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -5330,7 +5454,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -5435,7 +5559,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -5542,7 +5666,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -5644,7 +5768,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -5756,7 +5880,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -5863,7 +5987,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -5965,7 +6089,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -6067,7 +6191,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -6174,7 +6298,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -6276,7 +6400,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -6383,7 +6507,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -6485,7 +6609,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -6587,7 +6711,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -6689,7 +6813,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -6796,7 +6920,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -6972,7 +7096,7 @@ that then see the addAt method.

    Source:
    @@ -7197,7 +7321,7 @@ Group.addAll('x', 10) will add 10 to the child.x value.

    Source:
    @@ -7411,7 +7535,7 @@ The child is added to the Group at the location specified by the index value, th
    Source:
    @@ -7614,7 +7738,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -7783,7 +7907,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -7917,7 +8041,7 @@ If the object doesn't have a center property it will be set to object.x + object
    Source:
    @@ -8040,7 +8164,7 @@ If the object doesn't have a center property it will be set to object.x + object
    Source:
    @@ -8279,7 +8403,7 @@ After the method parameter and context you can add as many extra parameters as y
    Source:
    @@ -8477,7 +8601,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -8646,7 +8770,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -8938,7 +9062,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -9186,7 +9310,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -9283,7 +9407,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -9380,7 +9504,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -9692,7 +9816,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -9974,7 +10098,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -10121,7 +10245,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -10267,7 +10391,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -10449,7 +10573,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -10642,7 +10766,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -10711,7 +10835,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -10888,7 +11012,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -10911,6 +11035,213 @@ Group.divideAll('x', 2) will half the child.x value.

    +
    + + + +
    +

    filter(predicate, checkExists) → {Phaser.ArrayList}

    + + +
    +
    + + +
    +

    Allows you to obtain a Phaser.ArrayList of children that return true for the given predicate +For example: + var healthyList = Group.filter(function(child, index, children) { + return child.health > 10 ? true : false; + }, true); + healthyList.callAll('attack'); +Note: Currently this will skip any children which are Groups themselves.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    predicate + + +function + + + + + + + + + + + +

    The function that each child will be evaluated against. Each child of the Group will be passed to it as its first parameter, the index as the second, and the entire child array as the third

    checkExists + + +boolean + + + + + + <optional>
    + + + + + +
    + + false + +

    If set only children with exists=true will be passed to the callback, otherwise all children will be passed.

    + + + + +
    + + + + + + + +
    Inherited From:
    +
    + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    Returns an array list containing all the children that the predicate returned true for

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.ArrayList + + +
    +
    + + + + +
    @@ -11104,7 +11435,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -11320,7 +11651,7 @@ Note: Currently this will skip any children which are Groups themselves.

    Source:
    @@ -11468,7 +11799,7 @@ For example: Group.forEachAlive(causeDamage, this, 500)

    Source:
    @@ -11616,7 +11947,7 @@ For example: Group.forEachDead(bringToLife, this)

    Source:
    @@ -11764,7 +12095,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -11887,7 +12218,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -11984,7 +12315,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -12082,7 +12413,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -12180,7 +12511,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -12326,7 +12657,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -12472,7 +12803,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -12641,7 +12972,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -12738,7 +13069,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -12907,7 +13238,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -13217,7 +13548,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -13309,7 +13640,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -13604,7 +13935,7 @@ The particles are stored internally waiting to be emitted via Emitter.start.

    Source:
    @@ -13750,7 +14081,7 @@ The particles are stored internally waiting to be emitted via Emitter.start.

    Source:
    @@ -13896,7 +14227,7 @@ The particles are stored internally waiting to be emitted via Emitter.start.

    Source:
    @@ -14112,7 +14443,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -14186,7 +14517,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -14283,7 +14614,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -14357,7 +14688,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -14431,7 +14762,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -14672,7 +15003,7 @@ reset the Group cursor and optionally destroy the child.

    Source:
    @@ -14878,7 +15209,7 @@ The Group container remains on the display list.

    Source:
    @@ -15132,7 +15463,7 @@ The Group container remains on the display list.

    Source:
    @@ -15278,7 +15609,7 @@ The Group container remains on the display list.

    Source:
    @@ -15444,7 +15775,7 @@ The Group container remains on the display list.

    Source:
    @@ -15541,7 +15872,7 @@ The Group container remains on the display list.

    Source:
    @@ -15610,7 +15941,7 @@ The Group container remains on the display list.

    Source:
    @@ -15733,7 +16064,7 @@ The Group container remains on the display list.

    Source:
    @@ -16122,7 +16453,7 @@ The operation parameter controls how the new value is assigned to the property,
    Source:
    @@ -16478,7 +16809,7 @@ If you need that ability please see Group.setAllChildren.

    Source:
    @@ -16811,7 +17142,7 @@ Unlike with Group.setAll the property is NOT set on child Groups itself.

    Source:
    @@ -17107,7 +17438,7 @@ If rate is zero, which is the default, the particle won't change alpha - instead
    Source:
    @@ -17399,7 +17730,7 @@ Operation 0 means set the existing value to the given value, or if force is Source:
    @@ -17599,7 +17930,7 @@ Operation 0 means set the existing value to the given value, or if force is Source:
    @@ -17973,7 +18304,7 @@ If rate is zero, which is the default, the particle won't change scale during up
    Source:
    @@ -18114,7 +18445,7 @@ If rate is zero, which is the default, the particle won't change scale during up
    Source:
    @@ -18291,7 +18622,7 @@ If rate is zero, which is the default, the particle won't change scale during up
    Source:
    @@ -18468,7 +18799,7 @@ If rate is zero, which is the default, the particle won't change scale during up
    Source:
    @@ -18651,7 +18982,7 @@ For example to depth sort Sprites for Zelda-style game you might call grou
    Source:
    @@ -18945,7 +19276,7 @@ For example to depth sort Sprites for Zelda-style game you might call grou
    Source:
    @@ -19138,7 +19469,7 @@ Group.subAll('x', 10) will minus 10 from the child.x value.

    Source:
    @@ -19285,7 +19616,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -19354,7 +19685,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -19428,7 +19759,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -19597,7 +19928,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -19648,7 +19979,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:30 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:58 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Particles.Arcade.html b/docs/Phaser.Particles.Arcade.html new file mode 100644 index 000000000..d6f4c8b9c --- /dev/null +++ b/docs/Phaser.Particles.Arcade.html @@ -0,0 +1,729 @@ + + + + + + Phaser Class: Arcade + + + + + + + + + + +
    + + +
    + + +
    + +
    + + + +

    Class: Arcade

    +
    + +
    +

    + Phaser.Particles. + + Arcade +

    + +
    + +
    +
    + + + + +
    +

    new Arcade()

    + + +
    +
    + + +
    +

    Arcade Particles is a Particle System integrated with Arcade Physics.

    +
    + + + + + + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + + + +
    + + +
    + + + + + + + + +

    Classes

    + +
    + + +
    + Emitter +
    +
    + +
    + +
    + + + + + + + + + + + +
    + +
    + + + + +
    + +
    +
    + + + + Phaser Copyright © 2012-2014 Photon Storm Ltd. + +
    + + + Documentation generated by JSDoc 3.3.0-dev + on Thu Oct 09 2014 16:09:58 GMT+0100 (BST) using the DocStrap template. + +
    +
    + + +
    +
    +
    + +
    +
    + +
    + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/Phaser.Particles.html b/docs/Phaser.Particles.html index a9315b856..b8b7e2de3 100644 --- a/docs/Phaser.Particles.html +++ b/docs/Phaser.Particles.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Particles -

    Phaser Particles

    +

    Phaser.Particles

    @@ -643,7 +651,7 @@
    Source:
    @@ -678,6 +686,20 @@ +

    Classes

    + +
    + + +
    + Arcade +
    +
    + +
    + +
    + @@ -771,7 +793,7 @@
    Source:
    @@ -873,7 +895,7 @@
    Source:
    @@ -978,7 +1000,7 @@
    Source:
    @@ -1092,7 +1114,7 @@
    Source:
    @@ -1233,7 +1255,7 @@
    Source:
    @@ -1302,7 +1324,7 @@
    Source:
    @@ -1353,7 +1375,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:30 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:58 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.Arcade.Body.html b/docs/Phaser.Physics.Arcade.Body.html index a078dfa33..d582602af 100644 --- a/docs/Phaser.Physics.Arcade.Body.html +++ b/docs/Phaser.Physics.Arcade.Body.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Body -

    Arcade Physics Body Constructor

    +

    Phaser.Physics.Arcade.Body

    @@ -644,7 +652,7 @@ the Sprite itself. For example you can set the velocity, acceleration, bounce va
    Source:
    @@ -772,7 +780,7 @@ the Sprite itself. For example you can set the velocity, acceleration, bounce va
    Source:
    @@ -877,7 +885,7 @@ the Sprite itself. For example you can set the velocity, acceleration, bounce va
    Source:
    @@ -982,7 +990,7 @@ the Sprite itself. For example you can set the velocity, acceleration, bounce va
    Source:
    @@ -1084,7 +1092,7 @@ the Sprite itself. For example you can set the velocity, acceleration, bounce va
    Source:
    @@ -1189,7 +1197,7 @@ the Sprite itself. For example you can set the velocity, acceleration, bounce va
    Source:
    @@ -1294,7 +1302,7 @@ the Sprite itself. For example you can set the velocity, acceleration, bounce va
    Source:
    @@ -1399,7 +1407,7 @@ the Sprite itself. For example you can set the velocity, acceleration, bounce va
    Source:
    @@ -1506,7 +1514,7 @@ For example if blocked.up is true then the Body cannot move up.

    Source:
    @@ -1608,7 +1616,7 @@ For example if blocked.up is true then the Body cannot move up.

    Source:
    @@ -1710,7 +1718,7 @@ For example if blocked.up is true then the Body cannot move up.

    Source:
    @@ -1812,7 +1820,7 @@ For example if blocked.up is true then the Body cannot move up.

    Source:
    @@ -1919,7 +1927,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2025,7 +2033,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2135,7 +2143,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -2245,7 +2253,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -2347,7 +2355,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -2449,7 +2457,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -2555,7 +2563,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -2660,7 +2668,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -2762,7 +2770,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -2864,7 +2872,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -2966,7 +2974,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -3068,7 +3076,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -3170,7 +3178,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -3267,7 +3275,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -3372,7 +3380,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -3477,7 +3485,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -3582,7 +3590,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -3684,7 +3692,7 @@ Used in combination with your own collision processHandler you can create whatev
    Source:
    @@ -3795,7 +3803,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -3897,7 +3905,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -3999,7 +4007,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -4105,7 +4113,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -4211,7 +4219,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -4313,7 +4321,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -4415,7 +4423,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -4517,7 +4525,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -4619,7 +4627,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -4721,7 +4729,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -4823,7 +4831,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -4925,7 +4933,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -5027,7 +5035,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -5129,7 +5137,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -5231,7 +5239,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -5333,7 +5341,7 @@ If you want the physics system to move the body around, then set moves to true.<
    Source:
    @@ -5440,7 +5448,7 @@ Set this padding value to add extra padding to its bounds. tilePadding.x applied
    Source:
    @@ -5547,7 +5555,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -5649,7 +5657,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -5751,7 +5759,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -5857,7 +5865,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -5959,7 +5967,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6061,7 +6069,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6163,7 +6171,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6228,7 +6236,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6297,7 +6305,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6389,7 +6397,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6481,7 +6489,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6573,7 +6581,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6665,7 +6673,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6757,7 +6765,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6898,7 +6906,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -6990,7 +6998,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -7082,7 +7090,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -7174,7 +7182,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -7243,7 +7251,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -7490,7 +7498,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -7733,7 +7741,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -7874,7 +7882,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -8101,7 +8109,7 @@ is the position of the Body relative to the top-left of the Sprite.

    Source:
    @@ -8170,7 +8178,7 @@ is the position of the Body relative to the top-left of the Sprite.

    Source:
    @@ -8221,7 +8229,7 @@ is the position of the Body relative to the top-left of the Sprite.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:31 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:59 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.Arcade.html b/docs/Phaser.Physics.Arcade.html index e3ad25951..fa229cf0d 100644 --- a/docs/Phaser.Physics.Arcade.html +++ b/docs/Phaser.Physics.Arcade.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Arcade -

    Arcade Physics Constructor

    +

    Phaser.Physics.Arcade

    @@ -561,7 +569,7 @@
    -

    Arcade Physics constructor.

    +

    The Arcade Physics world. Contains Arcade Physics related collision, overlap and motion methods.

    @@ -643,7 +651,7 @@
    Source:
    @@ -785,7 +793,7 @@
    Source:
    @@ -892,7 +900,7 @@ For example checkCollision.down = false means Bodies cannot collide with the Wor
    Source:
    @@ -994,7 +1002,7 @@ For example checkCollision.down = false means Bodies cannot collide with the Wor
    Source:
    @@ -1096,7 +1104,7 @@ For example checkCollision.down = false means Bodies cannot collide with the Wor
    Source:
    @@ -1198,7 +1206,7 @@ For example checkCollision.down = false means Bodies cannot collide with the Wor
    Source:
    @@ -1300,7 +1308,7 @@ For example checkCollision.down = false means Bodies cannot collide with the Wor
    Source:
    @@ -1402,7 +1410,7 @@ For example checkCollision.down = false means Bodies cannot collide with the Wor
    Source:
    @@ -1504,7 +1512,7 @@ For example checkCollision.down = false means Bodies cannot collide with the Wor
    Source:
    @@ -1606,7 +1614,7 @@ For example checkCollision.down = false means Bodies cannot collide with the Wor
    Source:
    @@ -1708,7 +1716,7 @@ For example checkCollision.down = false means Bodies cannot collide with the Wor
    Source:
    @@ -1810,7 +1818,7 @@ For example checkCollision.down = false means Bodies cannot collide with the Wor
    Source:
    @@ -2095,7 +2103,7 @@ Note: The display object doesn't stop moving once it reaches the destination coo
    Source:
    @@ -2409,7 +2417,7 @@ Note: The display object doesn't stop moving once it reaches the destination coo
    Source:
    @@ -2756,7 +2764,7 @@ Note: The display object doesn't stop moving once it reaches the destination coo
    Source:
    @@ -2993,7 +3001,7 @@ One way to use this is: accelerationFromRotation(rotation, 200, sprite.accelerat
    Source:
    @@ -3159,7 +3167,7 @@ One way to use this is: accelerationFromRotation(rotation, 200, sprite.accelerat
    Source:
    @@ -3343,7 +3351,7 @@ One way to use this is: accelerationFromRotation(rotation, 200, sprite.accelerat
    Source:
    @@ -3530,7 +3538,7 @@ One way to use this is: accelerationFromRotation(rotation, 200, sprite.accelerat
    Source:
    @@ -3649,7 +3657,7 @@ NOTE: This function is not recursive, and will not test against children of obje Phaser.Particles.Emitter | -Phaser.Tilemap +Phaser.TilemapLayer | array @@ -3674,7 +3682,7 @@ NOTE: This function is not recursive, and will not test against children of obje -

    The first object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.Tilemap.

    +

    The first object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.TilemapLayer.

    @@ -3696,7 +3704,7 @@ NOTE: This function is not recursive, and will not test against children of obje Phaser.Particles.Emitter | -Phaser.Tilemap +Phaser.TilemapLayer | array @@ -3721,7 +3729,7 @@ NOTE: This function is not recursive, and will not test against children of obje -

    The second object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.Tilemap.

    +

    The second object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.TilemapLayer.

    @@ -3868,7 +3876,7 @@ NOTE: This function is not recursive, and will not test against children of obje
    Source:
    @@ -4205,7 +4213,7 @@ Based on a function in Flixel by @ADAMATOMIC

    Source:
    @@ -4369,7 +4377,7 @@ Based on a function in Flixel by @ADAMATOMIC

    Source:
    @@ -4555,7 +4563,7 @@ If you need to calculate from the center of a display object instead use the met
    Source:
    @@ -4744,7 +4752,7 @@ If you need to calculate from the center of a display object instead use the met
    Source:
    @@ -4947,7 +4955,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -5066,7 +5074,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -5293,7 +5301,7 @@ Note that the children are not checked for depth order, but simply if they overl
    Source:
    @@ -5457,7 +5465,7 @@ Note that the children are not checked for depth order, but simply if they overl
    Source:
    @@ -5732,7 +5740,7 @@ Note: Doesn't take into account acceleration, maxVelocity or drag (if you've set
    Source:
    @@ -6008,7 +6016,7 @@ Note: The display object doesn't stop moving once it reaches the destination coo
    Source:
    @@ -6318,7 +6326,7 @@ Note: Doesn't take into account acceleration, maxVelocity or drag (if you've set
    Source:
    @@ -6648,7 +6656,7 @@ NOTE: This function is not recursive, and will not test against children of obje
    Source:
    @@ -6858,7 +6866,7 @@ NOTE: This function is not recursive, and will not test against children of obje
    Source:
    @@ -6927,7 +6935,7 @@ NOTE: This function is not recursive, and will not test against children of obje
    Source:
    @@ -7045,7 +7053,7 @@ NOTE: This function is not recursive, and will not test against children of obje
    Source:
    @@ -7259,7 +7267,7 @@ One way to use this is: velocityFromAngle(angle, 200, sprite.velocity) which wil
    Source:
    @@ -7498,7 +7506,7 @@ One way to use this is: velocityFromRotation(rotation, 200, sprite.velocity) whi
    Source:
    @@ -7574,7 +7582,7 @@ One way to use this is: velocityFromRotation(rotation, 200, sprite.velocity) whi Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:31 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:59 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.Ninja.AABB.html b/docs/Phaser.Physics.Ninja.AABB.html index 2e1c3b60f..c27294758 100644 --- a/docs/Phaser.Physics.Ninja.AABB.html +++ b/docs/Phaser.Physics.Ninja.AABB.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ AABB -

    Arcade Physics Constructor

    +

    Phaser.Physics.Ninja.AABB

    @@ -736,7 +744,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -864,7 +872,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -966,7 +974,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1068,7 +1076,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1170,7 +1178,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1272,7 +1280,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1374,7 +1382,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1476,7 +1484,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1578,7 +1586,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1680,7 +1688,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1782,7 +1790,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1896,7 +1904,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2014,7 +2022,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2083,7 +2091,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2152,7 +2160,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2221,7 +2229,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2408,7 +2416,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2618,7 +2626,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2828,7 +2836,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -3038,7 +3046,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -3248,7 +3256,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -3458,7 +3466,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -3668,7 +3676,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -3878,7 +3886,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -4088,7 +4096,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -4321,7 +4329,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -4531,7 +4539,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -4741,7 +4749,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -4928,7 +4936,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -5002,7 +5010,7 @@ Note: This class could be massively optimised and reduced in size. I leave that Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:32 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:59 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.Ninja.Body.html b/docs/Phaser.Physics.Ninja.Body.html index adb8cdc42..9acebf200 100644 --- a/docs/Phaser.Physics.Ninja.Body.html +++ b/docs/Phaser.Physics.Ninja.Body.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Body -

    Ninja Physics Body Constructor

    +

    Phaser.Physics.Ninja.Body

    @@ -968,7 +976,7 @@ the Sprite itself. For example you can set the velocity, bounce values etc all o
    Source:
    @@ -1096,7 +1104,7 @@ the Sprite itself. For example you can set the velocity, bounce values etc all o
    Source:
    @@ -1198,7 +1206,7 @@ the Sprite itself. For example you can set the velocity, bounce values etc all o
    Source:
    @@ -1300,7 +1308,7 @@ the Sprite itself. For example you can set the velocity, bounce values etc all o
    Source:
    @@ -1405,7 +1413,7 @@ the Sprite itself. For example you can set the velocity, bounce values etc all o
    Source:
    @@ -1512,7 +1520,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -1614,7 +1622,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -1720,7 +1728,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -1825,7 +1833,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -1927,7 +1935,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2032,7 +2040,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2134,7 +2142,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2239,7 +2247,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2341,7 +2349,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2446,7 +2454,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2551,7 +2559,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2653,7 +2661,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2755,7 +2763,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2857,7 +2865,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -2959,7 +2967,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -3061,7 +3069,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -3163,7 +3171,7 @@ For example checkCollision.up = false means it won't collide when the collision
    Source:
    @@ -3270,7 +3278,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -3372,7 +3380,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -3474,7 +3482,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -3580,7 +3588,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -3682,7 +3690,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -3784,7 +3792,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -3886,7 +3894,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -3951,7 +3959,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -4043,7 +4051,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -4135,7 +4143,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -4227,7 +4235,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -4319,7 +4327,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -4388,7 +4396,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -4457,7 +4465,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -4704,7 +4712,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -4773,7 +4781,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -4842,7 +4850,7 @@ touching.up = true means the collision happened to the top of this Body for exam
    Source:
    @@ -4893,7 +4901,7 @@ touching.up = true means the collision happened to the top of this Body for exam Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:32 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:00 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.Ninja.Circle.html b/docs/Phaser.Physics.Ninja.Circle.html index 22d408e7f..bbe74da71 100644 --- a/docs/Phaser.Physics.Ninja.Circle.html +++ b/docs/Phaser.Physics.Ninja.Circle.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Circle -

    Arcade Physics Constructor

    +

    Phaser.Physics.Ninja.Circle

    @@ -713,7 +721,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -841,7 +849,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -943,7 +951,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1045,7 +1053,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1147,7 +1155,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1249,7 +1257,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1351,7 +1359,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1453,7 +1461,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1555,7 +1563,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1657,7 +1665,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1759,7 +1767,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1861,7 +1869,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -1975,7 +1983,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2067,7 +2075,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2136,7 +2144,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2205,7 +2213,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2438,7 +2446,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2694,7 +2702,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -2950,7 +2958,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -3206,7 +3214,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -3462,7 +3470,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -3718,7 +3726,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -3974,7 +3982,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -4230,7 +4238,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -4486,7 +4494,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -4719,7 +4727,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -4929,7 +4937,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -5162,7 +5170,7 @@ Note: This class could be massively optimised and reduced in size. I leave that
    Source:
    @@ -5236,7 +5244,7 @@ Note: This class could be massively optimised and reduced in size. I leave that Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:32 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:00 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.Ninja.Tile.html b/docs/Phaser.Physics.Ninja.Tile.html index 2ea3ee3a1..84fb5c87a 100644 --- a/docs/Phaser.Physics.Ninja.Tile.html +++ b/docs/Phaser.Physics.Ninja.Tile.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Tile -

    The Ninja Physics Tile class. Based on code by Metanet Software.

    +

    Phaser.Physics.Ninja.Tile

    @@ -842,7 +850,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -970,7 +978,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -1072,7 +1080,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -1174,7 +1182,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -1276,7 +1284,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -1378,7 +1386,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -1480,7 +1488,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -1582,7 +1590,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -1684,7 +1692,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -1786,7 +1794,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -1888,7 +1896,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -1990,7 +1998,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -2092,7 +2100,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -2194,7 +2202,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -2296,7 +2304,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -2398,7 +2406,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -2463,7 +2471,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -2532,7 +2540,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -2601,7 +2609,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -2670,7 +2678,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -2880,7 +2888,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -2998,7 +3006,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled
    Source:
    @@ -3049,7 +3057,7 @@ Also note that as Tiles are primarily used for levels they have gravity disabled Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:32 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:00 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.Ninja.html b/docs/Phaser.Physics.Ninja.html index 40da30579..bafb72963 100644 --- a/docs/Phaser.Physics.Ninja.html +++ b/docs/Phaser.Physics.Ninja.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Ninja -

    Ninja Physics Constructor

    +

    Phaser.Physics.Ninja

    @@ -656,7 +664,7 @@
    Source:
    @@ -822,7 +830,7 @@
    Source:
    @@ -924,7 +932,7 @@
    Source:
    @@ -1026,7 +1034,7 @@
    Source:
    @@ -1128,7 +1136,7 @@
    Source:
    @@ -1230,7 +1238,7 @@
    Source:
    @@ -1332,7 +1340,7 @@
    Source:
    @@ -1434,7 +1442,7 @@
    Source:
    @@ -1597,7 +1605,7 @@
    Source:
    @@ -1691,7 +1699,7 @@ The collideCallback is an optional function that is only called if two sprites c Phaser.Particles.Emitter | -Phaser.Tilemap +Phaser.TilemapLayer @@ -1713,7 +1721,7 @@ The collideCallback is an optional function that is only called if two sprites c -

    The first object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.Tilemap.

    +

    The first object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.TilemapLayer.

    @@ -1735,7 +1743,7 @@ The collideCallback is an optional function that is only called if two sprites c Phaser.Particles.Emitter | -Phaser.Tilemap +Phaser.TilemapLayer | array @@ -1760,7 +1768,7 @@ The collideCallback is an optional function that is only called if two sprites c -

    The second object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.Tilemap.

    +

    The second object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.TilemapLayer.

    @@ -1907,7 +1915,7 @@ The collideCallback is an optional function that is only called if two sprites c
    Source:
    @@ -2139,7 +2147,7 @@ Where each element of the array is a tile in your tilemap and the resulting Ninj
    Source:
    @@ -2459,7 +2467,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -2639,7 +2647,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -2758,7 +2766,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -2973,7 +2981,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -3194,7 +3202,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -3496,7 +3504,7 @@ The second parameter can be an array of objects, of differing types.

    Source:
    @@ -3660,7 +3668,7 @@ The second parameter can be an array of objects, of differing types.

    Source:
    @@ -3870,7 +3878,7 @@ The second parameter can be an array of objects, of differing types.

    Source:
    @@ -3939,7 +3947,7 @@ The second parameter can be an array of objects, of differing types.

    Source:
    @@ -3990,7 +3998,7 @@ The second parameter can be an array of objects, of differing types.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:31 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:59 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.Body.html b/docs/Phaser.Physics.P2.Body.html index 1f0856e7a..bfad47eec 100644 --- a/docs/Phaser.Physics.P2.Body.html +++ b/docs/Phaser.Physics.P2.Body.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Body -

    Physics Body Constructor

    +

    Phaser.Physics.P2.Body

    @@ -818,7 +826,7 @@ Note: When a game object is given a P2 body it has its anchor x/y set to 0.5, so
    Source:
    @@ -955,7 +963,7 @@ Note: When a game object is given a P2 body it has its anchor x/y set to 0.5, so
    Source:
    @@ -1066,7 +1074,7 @@ Note: When a game object is given a P2 body it has its anchor x/y set to 0.5, so
    Source:
    @@ -1177,7 +1185,7 @@ Note: When a game object is given a P2 body it has its anchor x/y set to 0.5, so
    Source:
    @@ -1279,7 +1287,7 @@ Note: When a game object is given a P2 body it has its anchor x/y set to 0.5, so
    Source:
    @@ -1387,7 +1395,7 @@ If you wish to work in radians instead of degrees use the property Body.rotation
    Source:
    @@ -1493,7 +1501,7 @@ If you wish to work in radians instead of degrees use the property Body.rotation
    Source:
    @@ -1595,7 +1603,7 @@ If you wish to work in radians instead of degrees use the property Body.rotation
    Source:
    @@ -1697,7 +1705,7 @@ If you wish to work in radians instead of degrees use the property Body.rotation
    Source:
    @@ -1799,7 +1807,7 @@ If you wish to work in radians instead of degrees use the property Body.rotation
    Source:
    @@ -1908,7 +1916,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -2014,7 +2022,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -2116,7 +2124,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -2218,7 +2226,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -2320,7 +2328,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -2422,7 +2430,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -2524,7 +2532,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -2626,7 +2634,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -2728,7 +2736,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -2830,7 +2838,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -2932,7 +2940,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -3034,7 +3042,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -3136,7 +3144,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -3238,7 +3246,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -3340,7 +3348,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -3442,7 +3450,7 @@ after setting this it will not proactively set them to collide with the
    Source:
    @@ -3549,7 +3557,7 @@ The event will be sent 4 parameters: The body it is in contact with, the shape f
    Source:
    @@ -3656,7 +3664,7 @@ The event will be sent 3 parameters: The body it is in contact with, the shape f
    Source:
    @@ -3758,7 +3766,7 @@ The event will be sent 3 parameters: The body it is in contact with, the shape f
    Source:
    @@ -3865,7 +3873,7 @@ If you wish to work in degrees instead of radians use the Body.angle property in
    Source:
    @@ -3967,7 +3975,7 @@ If you wish to work in degrees instead of radians use the Body.angle property in
    Source:
    @@ -4069,7 +4077,7 @@ If you wish to work in degrees instead of radians use the Body.angle property in
    Source:
    @@ -4171,7 +4179,7 @@ If you wish to work in degrees instead of radians use the Body.angle property in
    Source:
    @@ -4273,7 +4281,7 @@ If you wish to work in degrees instead of radians use the Body.angle property in
    Source:
    @@ -4375,7 +4383,7 @@ If you wish to work in degrees instead of radians use the Body.angle property in
    Source:
    @@ -4477,7 +4485,7 @@ If you wish to work in degrees instead of radians use the Body.angle property in
    Source:
    @@ -4579,7 +4587,7 @@ If you wish to work in degrees instead of radians use the Body.angle property in
    Source:
    @@ -4681,7 +4689,7 @@ If you wish to work in degrees instead of radians use the Body.angle property in
    Source:
    @@ -4964,7 +4972,7 @@ You can control the offset from the center of the body and the rotation.

    Source:
    @@ -5238,7 +5246,7 @@ You can control the offset from the center of the body and the rotation.

    Source:
    @@ -5379,7 +5387,7 @@ You can control the offset from the center of the body and the rotation.

    Source:
    @@ -5655,7 +5663,7 @@ You can control the offset from the center of the body and the rotation.

    Source:
    @@ -5894,7 +5902,7 @@ You can control the offset from the center of the body and the rotation.

    Source:
    @@ -6059,7 +6067,7 @@ The shape data format is based on the custom phaser export in.

    Source:
    @@ -6275,7 +6283,7 @@ The shape data format is based on the custom phaser export in.

    Source:
    @@ -6595,7 +6603,7 @@ This function expects the x.y values to be given in pixels. If you want to provi
    Source:
    @@ -6904,7 +6912,7 @@ This function expects the x.y values to be given in pixels. If you want to provi
    Source:
    @@ -7179,7 +7187,7 @@ Will automatically update the mass properties and bounding radius.

    Source:
    @@ -7271,7 +7279,7 @@ Will automatically update the mass properties and bounding radius.

    Source:
    @@ -7340,7 +7348,7 @@ Will automatically update the mass properties and bounding radius.

    Source:
    @@ -7458,7 +7466,7 @@ Will automatically update the mass properties and bounding radius.

    Source:
    @@ -7625,7 +7633,7 @@ Will automatically update the mass properties and bounding radius.

    Source:
    @@ -7839,7 +7847,7 @@ Will automatically update the mass properties and bounding radius.

    Source:
    @@ -7908,7 +7916,7 @@ Will automatically update the mass properties and bounding radius.

    Source:
    @@ -8138,7 +8146,7 @@ Will automatically update the mass properties and bounding radius.

    Source:
    @@ -8314,7 +8322,7 @@ It also happens mid-step. So do not destroy a Body during this callback, instead
    Source:
    @@ -8482,7 +8490,7 @@ It also happens mid-step. So do not destroy a Body during this callback, instead
    Source:
    @@ -8551,7 +8559,7 @@ It also happens mid-step. So do not destroy a Body during this callback, instead
    Source:
    @@ -8620,7 +8628,7 @@ It also happens mid-step. So do not destroy a Body during this callback, instead
    Source:
    @@ -8784,7 +8792,7 @@ It also happens mid-step. So do not destroy a Body during this callback, instead
    Source:
    @@ -8926,7 +8934,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -9045,7 +9053,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -9164,7 +9172,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -9283,7 +9291,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -9402,7 +9410,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -9521,7 +9529,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -9590,7 +9598,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -9659,7 +9667,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -9728,7 +9736,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -9858,7 +9866,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -10128,7 +10136,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -10247,7 +10255,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -10365,7 +10373,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -10483,7 +10491,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -10734,7 +10742,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -10896,7 +10904,7 @@ This also resets the collisionMask.

    Source:
    @@ -11058,7 +11066,7 @@ If you only wish to apply it to a specific Shape in this Body then provide that
    Source:
    @@ -11353,7 +11361,7 @@ If you wish to create a Rectangle to match the size of a Sprite or Image see Bod
    Source:
    @@ -11511,7 +11519,7 @@ If no Sprite is given it defaults to using the parent of this Body.

    Source:
    @@ -11603,7 +11611,7 @@ If no Sprite is given it defaults to using the parent of this Body.

    Source:
    @@ -11672,7 +11680,7 @@ If no Sprite is given it defaults to using the parent of this Body.

    Source:
    @@ -11741,7 +11749,7 @@ If no Sprite is given it defaults to using the parent of this Body.

    Source:
    @@ -11810,7 +11818,7 @@ If no Sprite is given it defaults to using the parent of this Body.

    Source:
    @@ -11879,7 +11887,7 @@ If no Sprite is given it defaults to using the parent of this Body.

    Source:
    @@ -11998,7 +12006,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -12145,7 +12153,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -12286,7 +12294,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -12416,7 +12424,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100
    Source:
    @@ -12467,7 +12475,7 @@ The speed is represented in pixels per second. So a value of 100 would move 100 Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:33 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:01 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.BodyDebug.html b/docs/Phaser.Physics.P2.BodyDebug.html index 8bf674f6e..f7168211c 100644 --- a/docs/Phaser.Physics.P2.BodyDebug.html +++ b/docs/Phaser.Physics.P2.BodyDebug.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ BodyDebug -

    Physics Body Debug Constructor

    +

    Phaser.Physics.P2.BodyDebug

    @@ -691,7 +699,7 @@ So use sparingly and rarely (if ever) in production code.

    Source:
    @@ -833,7 +841,7 @@ So use sparingly and rarely (if ever) in production code.

    Source:
    @@ -940,7 +948,7 @@ So use sparingly and rarely (if ever) in production code.

    Source:
    @@ -1052,7 +1060,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1154,7 +1162,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1261,7 +1269,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1363,7 +1371,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1475,7 +1483,7 @@ When a new object is created it is passed the following parameters to its constr
    Source:
    @@ -1587,7 +1595,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1697,7 +1705,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1804,7 +1812,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1914,7 +1922,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -2027,7 +2035,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2134,7 +2142,117 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    + + + + + + + + + + + + + + + +
    +

    ignoreDestroy

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    ignoreDestroy + + +boolean + + + +

    A Group with ignoreDestroy set to true ignores all calls to its destroy method.

    +
    + + + + + + + + +
    Inherited From:
    +
    + + + + + + + + + + + +
    Default Value:
    +
    • false
    + + + +
    Source:
    +
    @@ -2241,7 +2359,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2348,7 +2466,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2455,7 +2573,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2562,7 +2680,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2664,7 +2782,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2776,7 +2894,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2883,7 +3001,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2990,7 +3108,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3097,7 +3215,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3204,7 +3322,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3316,7 +3434,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3428,7 +3546,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3535,7 +3653,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3711,7 +3829,7 @@ that then see the addAt method.

    Source:
    @@ -3936,7 +4054,7 @@ Group.addAll('x', 10) will add 10 to the child.x value.

    Source:
    @@ -4150,7 +4268,7 @@ The child is added to the Group at the location specified by the index value, th
    Source:
    @@ -4353,7 +4471,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4522,7 +4640,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4645,7 +4763,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4884,7 +5002,7 @@ After the method parameter and context you can add as many extra parameters as y
    Source:
    @@ -5082,7 +5200,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -5251,7 +5369,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -5543,7 +5661,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5791,7 +5909,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5883,7 +6001,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5957,7 +6075,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -6054,7 +6172,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -6366,7 +6484,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -6648,7 +6766,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -6795,7 +6913,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -6941,7 +7059,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -7123,7 +7241,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -7316,7 +7434,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7385,7 +7503,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7454,7 +7572,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7523,7 +7641,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7592,7 +7710,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7661,7 +7779,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7730,7 +7848,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7799,7 +7917,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7822,6 +7940,213 @@ Group.divideAll('x', 2) will half the child.x value.

    +
    + + + +
    +

    filter(predicate, checkExists) → {Phaser.ArrayList}

    + + +
    +
    + + +
    +

    Allows you to obtain a Phaser.ArrayList of children that return true for the given predicate +For example: + var healthyList = Group.filter(function(child, index, children) { + return child.health > 10 ? true : false; + }, true); + healthyList.callAll('attack'); +Note: Currently this will skip any children which are Groups themselves.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    predicate + + +function + + + + + + + + + + + +

    The function that each child will be evaluated against. Each child of the Group will be passed to it as its first parameter, the index as the second, and the entire child array as the third

    checkExists + + +boolean + + + + + + <optional>
    + + + + + +
    + + false + +

    If set only children with exists=true will be passed to the callback, otherwise all children will be passed.

    + + + + +
    + + + + + + + +
    Inherited From:
    +
    + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    Returns an array list containing all the children that the predicate returned true for

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.ArrayList + + +
    +
    + + + + +
    @@ -8015,7 +8340,7 @@ Note: Currently this will skip any children which are Groups themselves.

    Source:
    @@ -8163,7 +8488,7 @@ For example: Group.forEachAlive(causeDamage, this, 500)

    Source:
    @@ -8311,7 +8636,7 @@ For example: Group.forEachDead(bringToLife, this)

    Source:
    @@ -8459,7 +8784,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -8582,7 +8907,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -8679,7 +9004,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -8777,7 +9102,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8875,7 +9200,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9021,7 +9346,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9167,7 +9492,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9336,7 +9661,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9433,7 +9758,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9602,7 +9927,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9912,7 +10237,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -10058,7 +10383,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -10204,7 +10529,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -10420,7 +10745,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10494,7 +10819,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10591,7 +10916,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10665,7 +10990,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10739,7 +11064,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10831,7 +11156,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -11049,7 +11374,7 @@ reset the Group cursor and optionally destroy the child.

    Source:
    @@ -11255,7 +11580,7 @@ The Group container remains on the display list.

    Source:
    @@ -11509,7 +11834,7 @@ The Group container remains on the display list.

    Source:
    @@ -11655,7 +11980,7 @@ The Group container remains on the display list.

    Source:
    @@ -11821,7 +12146,7 @@ The Group container remains on the display list.

    Source:
    @@ -11918,7 +12243,7 @@ The Group container remains on the display list.

    Source:
    @@ -11987,7 +12312,7 @@ The Group container remains on the display list.

    Source:
    @@ -12110,7 +12435,7 @@ The Group container remains on the display list.

    Source:
    @@ -12499,7 +12824,7 @@ The operation parameter controls how the new value is assigned to the property,
    Source:
    @@ -12855,7 +13180,7 @@ If you need that ability please see Group.setAllChildren.

    Source:
    @@ -13188,7 +13513,7 @@ Unlike with Group.setAll the property is NOT set on child Groups itself.

    Source:
    @@ -13480,7 +13805,7 @@ Operation 0 means set the existing value to the given value, or if force is Source:
    @@ -13686,7 +14011,7 @@ For example to depth sort Sprites for Zelda-style game you might call grou
    Source:
    @@ -13879,7 +14204,7 @@ Group.subAll('x', 10) will minus 10 from the child.x value.

    Source:
    @@ -14026,7 +14351,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -14095,7 +14420,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -14164,7 +14489,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -14238,7 +14563,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -14407,7 +14732,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -14458,7 +14783,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:33 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:01 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.CollisionGroup.html b/docs/Phaser.Physics.P2.CollisionGroup.html index a92196870..c300ee0d0 100644 --- a/docs/Phaser.Physics.P2.CollisionGroup.html +++ b/docs/Phaser.Physics.P2.CollisionGroup.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ CollisionGroup -

    Physics Collision Group Constructor

    +

    Phaser.Physics.P2.CollisionGroup

    @@ -553,7 +561,7 @@
    -

    new CollisionGroup()

    +

    new CollisionGroup(bitmask)

    @@ -570,6 +578,55 @@ +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    bitmask + + +number + + + +

    The CollisionGroup bitmask.

    + +
    @@ -765,7 +822,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:33 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:01 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.ContactMaterial.html b/docs/Phaser.Physics.P2.ContactMaterial.html index c1ed17dbc..2b8a4da84 100644 --- a/docs/Phaser.Physics.P2.ContactMaterial.html +++ b/docs/Phaser.Physics.P2.ContactMaterial.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ ContactMaterial -

    Physics ContactMaterial Constructor

    +

    Phaser.Physics.P2.ContactMaterial

    @@ -621,7 +629,7 @@ - +

    First material participating in the contact material.

    @@ -652,7 +660,7 @@ - +

    Second material participating in the contact material.

    @@ -685,7 +693,7 @@ - +

    Additional configuration options.

    @@ -717,7 +725,7 @@
    Source:
    @@ -782,7 +790,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:34 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:01 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.DistanceConstraint.html b/docs/Phaser.Physics.P2.DistanceConstraint.html index 76c4dd60a..c8b319cb4 100644 --- a/docs/Phaser.Physics.P2.DistanceConstraint.html +++ b/docs/Phaser.Physics.P2.DistanceConstraint.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ DistanceConstraint -

    Physics DistanceConstraint Constructor

    +

    Phaser.Physics.P2.DistanceConstraint

    @@ -877,7 +885,7 @@
    Source:
    @@ -1005,7 +1013,7 @@
    Source:
    @@ -1107,7 +1115,7 @@
    Source:
    @@ -1150,7 +1158,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:34 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:02 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.FixtureList.html b/docs/Phaser.Physics.P2.FixtureList.html index 31ac811d3..ea1f2c81b 100644 --- a/docs/Phaser.Physics.P2.FixtureList.html +++ b/docs/Phaser.Physics.P2.FixtureList.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ FixtureList -

    Collection for generated P2 fixtures

    +

    Phaser.Physics.P2.FixtureList

    @@ -648,7 +656,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -784,7 +792,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -902,7 +910,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -1020,7 +1028,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -1138,7 +1146,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -1203,7 +1211,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -1272,7 +1280,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -1409,7 +1417,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -1546,7 +1554,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -1683,7 +1691,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -1820,7 +1828,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)<
    Source:
    @@ -1871,7 +1879,7 @@ during runtime (to remove parts, set masks, categories & sensor properties)< Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:34 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:02 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.GearConstraint.html b/docs/Phaser.Physics.P2.GearConstraint.html index 978a3f9a3..8a8986197 100644 --- a/docs/Phaser.Physics.P2.GearConstraint.html +++ b/docs/Phaser.Physics.P2.GearConstraint.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ GearConstraint -

    Physics GearConstraint Constructor

    +

    Phaser.Physics.P2.GearConstraint

    @@ -807,7 +815,7 @@
    Source:
    @@ -935,7 +943,7 @@
    Source:
    @@ -1037,7 +1045,7 @@
    Source:
    @@ -1080,7 +1088,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:34 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:02 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.InversePointProxy.html b/docs/Phaser.Physics.P2.InversePointProxy.html index f0c99aab3..27b840a81 100644 --- a/docs/Phaser.Physics.P2.InversePointProxy.html +++ b/docs/Phaser.Physics.P2.InversePointProxy.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ InversePointProxy -

    InversePointProxy

    +

    Phaser.Physics.P2.InversePointProxy

    @@ -666,7 +674,7 @@
    Source:
    @@ -794,7 +802,7 @@
    Source:
    @@ -896,7 +904,7 @@
    Source:
    @@ -998,7 +1006,7 @@
    Source:
    @@ -1100,7 +1108,7 @@
    Source:
    @@ -1143,7 +1151,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:34 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:02 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.LockConstraint.html b/docs/Phaser.Physics.P2.LockConstraint.html index a5974e9f5..e8938bae8 100644 --- a/docs/Phaser.Physics.P2.LockConstraint.html +++ b/docs/Phaser.Physics.P2.LockConstraint.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ LockConstraint -

    Physics LockConstraint Constructor

    +

    Phaser.Physics.P2.LockConstraint

    @@ -842,7 +850,7 @@
    Source:
    @@ -970,7 +978,7 @@
    Source:
    @@ -1072,7 +1080,7 @@
    Source:
    @@ -1115,7 +1123,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:34 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:02 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.Material.html b/docs/Phaser.Physics.P2.Material.html index 75466ec22..1f7ef3993 100644 --- a/docs/Phaser.Physics.P2.Material.html +++ b/docs/Phaser.Physics.P2.Material.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Material -

    Physics Material Constructor

    +

    Phaser.Physics.P2.Material

    @@ -553,7 +561,7 @@
    -

    new Material()

    +

    new Material(name)

    @@ -561,7 +569,8 @@
    -

    \o/ ~ "Because I'm a Material girl"

    +

    A P2 Material.

    +

    \o/ ~ "Because I'm a Material girl"

    @@ -570,6 +579,55 @@ +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    name + + +string + + + +

    The user defined name given to this Material.

    + +
    @@ -594,7 +652,7 @@
    Source:
    @@ -725,7 +783,7 @@
    Source:
    @@ -768,7 +826,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:35 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:02 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.PointProxy.html b/docs/Phaser.Physics.P2.PointProxy.html index a1590f991..58ee67057 100644 --- a/docs/Phaser.Physics.P2.PointProxy.html +++ b/docs/Phaser.Physics.P2.PointProxy.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ PointProxy -

    PointProxy

    +

    Phaser.Physics.P2.PointProxy

    @@ -666,7 +674,7 @@
    Source:
    @@ -794,7 +802,7 @@
    Source:
    @@ -896,7 +904,7 @@
    Source:
    @@ -998,7 +1006,7 @@
    Source:
    @@ -1100,7 +1108,7 @@
    Source:
    @@ -1143,7 +1151,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:35 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:03 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.PrismaticConstraint.html b/docs/Phaser.Physics.P2.PrismaticConstraint.html index 75b142e21..1136e8c69 100644 --- a/docs/Phaser.Physics.P2.PrismaticConstraint.html +++ b/docs/Phaser.Physics.P2.PrismaticConstraint.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ PrismaticConstraint -

    Physics PrismaticConstraint Constructor

    +

    Phaser.Physics.P2.PrismaticConstraint

    @@ -916,7 +924,7 @@
    Source:
    @@ -1044,7 +1052,7 @@
    Source:
    @@ -1146,7 +1154,7 @@
    Source:
    @@ -1189,7 +1197,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:35 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:03 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.RevoluteConstraint.html b/docs/Phaser.Physics.P2.RevoluteConstraint.html index 4dde10749..a5a322805 100644 --- a/docs/Phaser.Physics.P2.RevoluteConstraint.html +++ b/docs/Phaser.Physics.P2.RevoluteConstraint.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ RevoluteConstraint -

    Physics RevoluteConstraint Constructor

    +

    Phaser.Physics.P2.RevoluteConstraint

    @@ -878,7 +886,7 @@ The pivot points are given in world (pixel) coordinates.

    Source:
    @@ -1006,7 +1014,7 @@ The pivot points are given in world (pixel) coordinates.

    Source:
    @@ -1108,7 +1116,7 @@ The pivot points are given in world (pixel) coordinates.

    Source:
    @@ -1151,7 +1159,7 @@ The pivot points are given in world (pixel) coordinates.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:35 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:03 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.RotationalSpring.html b/docs/Phaser.Physics.P2.RotationalSpring.html index 59f9011db..85ca21c62 100644 --- a/docs/Phaser.Physics.P2.RotationalSpring.html +++ b/docs/Phaser.Physics.P2.RotationalSpring.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ RotationalSpring -

    Physics Spring Constructor

    +

    Phaser.Physics.P2.RotationalSpring

    @@ -844,7 +852,7 @@
    Source:
    @@ -972,7 +980,7 @@
    Source:
    @@ -1074,7 +1082,7 @@
    Source:
    @@ -1176,7 +1184,7 @@
    Source:
    @@ -1219,7 +1227,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:35 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:03 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.Spring.html b/docs/Phaser.Physics.P2.Spring.html index fb747db90..389248355 100644 --- a/docs/Phaser.Physics.P2.Spring.html +++ b/docs/Phaser.Physics.P2.Spring.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Spring -

    Physics Spring Constructor

    +

    Phaser.Physics.P2.Spring

    @@ -994,7 +1002,7 @@
    Source:
    @@ -1122,7 +1130,7 @@
    Source:
    @@ -1224,7 +1232,7 @@
    Source:
    @@ -1326,7 +1334,7 @@
    Source:
    @@ -1369,7 +1377,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:35 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:03 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.P2.html b/docs/Phaser.Physics.P2.html index 9bb106095..14aeca7b4 100644 --- a/docs/Phaser.Physics.P2.html +++ b/docs/Phaser.Physics.P2.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ P2 -

    Physics World Constructor

    +

    Phaser.Physics.P2

    @@ -560,6 +568,11 @@
    +
    +

    This is your main access to the P2 Physics World. +From here you can create materials, listen for events and add bodies into the physics simulation.

    +
    + @@ -682,7 +695,7 @@
    Source:
    @@ -936,7 +949,7 @@
    Source:
    @@ -1038,7 +1051,7 @@
    Source:
    @@ -1140,7 +1153,7 @@
    Source:
    @@ -1242,7 +1255,7 @@
    Source:
    @@ -1344,7 +1357,7 @@
    Source:
    @@ -1446,7 +1459,7 @@
    Source:
    @@ -1548,7 +1561,7 @@
    Source:
    @@ -1650,7 +1663,7 @@
    Source:
    @@ -1752,7 +1765,7 @@
    Source:
    @@ -1854,7 +1867,7 @@
    Source:
    @@ -1956,7 +1969,7 @@
    Source:
    @@ -2058,7 +2071,7 @@
    Source:
    @@ -2160,7 +2173,7 @@
    Source:
    @@ -2262,7 +2275,7 @@
    Source:
    @@ -2364,7 +2377,7 @@
    Source:
    @@ -2466,7 +2479,7 @@
    Source:
    @@ -2568,7 +2581,7 @@
    Source:
    @@ -2670,7 +2683,7 @@
    Source:
    @@ -2772,7 +2785,7 @@
    Source:
    @@ -2874,7 +2887,7 @@
    Source:
    @@ -2976,7 +2989,7 @@
    Source:
    @@ -3078,7 +3091,7 @@
    Source:
    @@ -3180,7 +3193,7 @@
    Source:
    @@ -3282,7 +3295,7 @@
    Source:
    @@ -3384,7 +3397,7 @@
    Source:
    @@ -3486,7 +3499,7 @@
    Source:
    @@ -3588,7 +3601,7 @@
    Source:
    @@ -3693,7 +3706,7 @@
    Source:
    @@ -3795,7 +3808,7 @@
    Source:
    @@ -3897,7 +3910,7 @@
    Source:
    @@ -4004,7 +4017,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -4106,7 +4119,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -4208,7 +4221,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -4310,7 +4323,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -4415,7 +4428,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -4517,7 +4530,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -4619,7 +4632,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -4733,7 +4746,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -4874,7 +4887,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -5015,7 +5028,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -5162,7 +5175,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -5303,7 +5316,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -5372,7 +5385,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -5539,7 +5552,7 @@ If sleeping is enabled, you might need to wake up the bodies if they fall asleep
    Source:
    @@ -5756,7 +5769,7 @@ Note that the polylines must be created in such a way that they can withstand po
    Source:
    @@ -6037,7 +6050,7 @@ Therefore understand it's a very expensive operation and not to be done in a cor
    Source:
    @@ -6528,7 +6541,7 @@ Therefore understand it's a very expensive operation and not to be done in a cor
    Source:
    @@ -6685,7 +6698,7 @@ Collision Groups are handled using bitmasks, therefore you have a fixed limit yo
    Source:
    @@ -6881,7 +6894,7 @@ Collision Groups are handled using bitmasks, therefore you have a fixed limit yo
    Source:
    @@ -7205,7 +7218,7 @@ Collision Groups are handled using bitmasks, therefore you have a fixed limit yo
    Source:
    @@ -7487,7 +7500,7 @@ Collision Groups are handled using bitmasks, therefore you have a fixed limit yo
    Source:
    @@ -7804,7 +7817,7 @@ Collision Groups are handled using bitmasks, therefore you have a fixed limit yo
    Source:
    @@ -7992,7 +8005,7 @@ Contact Materials have properties such as friction and restitution that allow fo
    Source:
    @@ -8483,7 +8496,7 @@ Contact Materials have properties such as friction and restitution that allow fo
    Source:
    @@ -8852,7 +8865,7 @@ See http://www.iforce2
    Source:
    @@ -9205,7 +9218,7 @@ The pivot points are given in world (pixel) coordinates.

    Source:
    @@ -9524,7 +9537,7 @@ The pivot points are given in world (pixel) coordinates.

    Source:
    @@ -9993,7 +10006,7 @@ The pivot points are given in world (pixel) coordinates.

    Source:
    @@ -10085,7 +10098,7 @@ The pivot points are given in world (pixel) coordinates.

    Source:
    @@ -10305,7 +10318,7 @@ Note: When the game object is enabled for P2 physics it has its anchor x/y set t
    Source:
    @@ -10447,7 +10460,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -10565,7 +10578,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -10634,7 +10647,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -10775,7 +10788,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -10867,7 +10880,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -11031,7 +11044,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -11126,7 +11139,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -11399,7 +11412,7 @@ A game object can only have 1 physics body active at any one time, and it can't
    Source:
    @@ -11542,7 +11555,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -11685,7 +11698,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -11777,7 +11790,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -11846,7 +11859,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -11966,7 +11979,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -12109,7 +12122,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -12250,7 +12263,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -12391,7 +12404,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -12509,7 +12522,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -12650,7 +12663,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -12791,7 +12804,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -12883,7 +12896,7 @@ If you need to modify this you can over-ride these functions via the Physics Con
    Source:
    @@ -13318,7 +13331,7 @@ You can optionally set which 'walls' to create: left, right, top or bottom.

    Source:
    @@ -13437,7 +13450,7 @@ In a busy world hundreds of impact events can be generated every step, so only e
    Source:
    @@ -13578,7 +13591,7 @@ In a busy world hundreds of impact events can be generated every step, so only e
    Source:
    @@ -13722,7 +13735,7 @@ Returning true from the callback will ensure they are checked in th
    Source:
    @@ -13791,7 +13804,7 @@ Returning true from the callback will ensure they are checked in th
    Source:
    @@ -13883,7 +13896,7 @@ Returning true from the callback will ensure they are checked in th
    Source:
    @@ -14023,7 +14036,7 @@ To fix this you need to adjust the bounds to use its own collision group first B
    Source:
    @@ -14074,7 +14087,7 @@ To fix this you need to adjust the bounds to use its own collision group first B Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:32 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:00 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Physics.html b/docs/Phaser.Physics.html index 81d2ecbf4..ea11afd90 100644 --- a/docs/Phaser.Physics.html +++ b/docs/Phaser.Physics.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -702,7 +710,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -818,7 +826,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -878,7 +886,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -938,7 +946,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -998,7 +1006,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1058,7 +1066,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1160,7 +1168,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1262,7 +1270,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1364,7 +1372,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1466,7 +1474,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1568,7 +1576,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1670,7 +1678,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1772,7 +1780,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1837,7 +1845,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1906,7 +1914,7 @@ faster (due to being much simpler) Arcade Physics system.

    Source:
    @@ -1948,7 +1956,8 @@ It can be for any of the physics systems that have been started:

    Phaser.Physics.Arcade - A light weight AABB based collision system with basic separation. Phaser.Physics.P2JS - A full-body advanced physics system supporting multiple object shapes, polygon loading, contact materials, springs and constraints. Phaser.Physics.NINJA - A port of Metanet Softwares N+ physics system. Advanced AABB and Circle vs. Tile collision. -Phaser.Physics.BOX2D and Phaser.Physics.CHIPMUNK are still in development.

    +Phaser.Physics.BOX2D - A port of https://code.google.com/p/box2d-html5 +Phaser.Physics.CHIPMUNK is still in development.

    If you require more control over what type of body is created, for example to create a Ninja Physics Circle instead of the default AABB, then see the individual physics systems enable methods instead of using this generic one.

    @@ -2129,7 +2138,7 @@ individual physics systems enable methods instead of using this gen
    Source:
    @@ -2198,7 +2207,7 @@ individual physics systems enable methods instead of using this gen
    Source:
    @@ -2267,7 +2276,7 @@ individual physics systems enable methods instead of using this gen
    Source:
    @@ -2562,7 +2571,7 @@ You can optionally set which 'walls' to create: left, right, top or bottom.

    Source:
    @@ -2631,7 +2640,7 @@ You can optionally set which 'walls' to create: left, right, top or bottom.

    Source:
    @@ -2921,7 +2930,7 @@ You can optionally set which 'walls' to create: left, right, top or bottom.

    Source:
    @@ -3044,7 +3053,7 @@ Phaser.Physics.BOX2D and Phaser.Physics.CHIPMUNK are still in development.

    Source:
    @@ -3113,7 +3122,7 @@ Phaser.Physics.BOX2D and Phaser.Physics.CHIPMUNK are still in development.

    Source:
    @@ -3164,7 +3173,7 @@ Phaser.Physics.BOX2D and Phaser.Physics.CHIPMUNK are still in development.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:31 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:59 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Plugin.html b/docs/Phaser.Plugin.html index d680bb88c..c67aced44 100644 --- a/docs/Phaser.Plugin.html +++ b/docs/Phaser.Plugin.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Plugin -

    Phaser - Plugin

    +

    Phaser.Plugin

    @@ -666,7 +674,7 @@
    Source:
    @@ -797,7 +805,7 @@
    Source:
    @@ -899,7 +907,7 @@
    Source:
    @@ -1004,7 +1012,7 @@
    Source:
    @@ -1109,7 +1117,7 @@
    Source:
    @@ -1214,7 +1222,7 @@
    Source:
    @@ -1319,7 +1327,7 @@
    Source:
    @@ -1424,7 +1432,7 @@
    Source:
    @@ -1526,7 +1534,7 @@
    Source:
    @@ -1631,7 +1639,7 @@
    Source:
    @@ -1696,7 +1704,7 @@
    Source:
    @@ -1766,7 +1774,7 @@ It is only called if visible is set to true.

    Source:
    @@ -1836,7 +1844,7 @@ It is only called if active is set to true.

    Source:
    @@ -1906,7 +1914,7 @@ It is only called if visible is set to true.

    Source:
    @@ -1976,7 +1984,7 @@ It is only called if active is set to true.

    Source:
    @@ -2027,7 +2035,7 @@ It is only called if active is set to true.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:36 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:03 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.PluginManager.html b/docs/Phaser.PluginManager.html index a8a047957..8c157b0be 100644 --- a/docs/Phaser.PluginManager.html +++ b/docs/Phaser.PluginManager.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ PluginManager -

    Phaser - PluginManager

    +

    Phaser.PluginManager

    @@ -643,7 +651,7 @@
    Source:
    @@ -771,7 +779,7 @@
    Source:
    @@ -873,7 +881,7 @@
    Source:
    @@ -1034,7 +1042,7 @@ The Plugin must have 2 properties: game and parent. Plugin.game is set to the ga
    Source:
    @@ -1126,7 +1134,7 @@ The Plugin must have 2 properties: game and parent. Plugin.game is set to the ga
    Source:
    @@ -1196,7 +1204,7 @@ It only calls plugins who have visible=true.

    Source:
    @@ -1267,7 +1275,7 @@ It only calls plugins who have active=true.

    Source:
    @@ -1337,7 +1345,7 @@ It only calls plugins who have active=true.

    Source:
    @@ -1455,7 +1463,7 @@ It only calls plugins who have active=true.

    Source:
    @@ -1524,7 +1532,7 @@ It only calls plugins who have active=true.

    Source:
    @@ -1594,7 +1602,7 @@ It only calls plugins who have visible=true.

    Source:
    @@ -1664,7 +1672,7 @@ It only calls plugins who have active=true.

    Source:
    @@ -1715,7 +1723,7 @@ It only calls plugins who have active=true.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:36 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:04 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Point.html b/docs/Phaser.Point.html index 448628732..4da283124 100644 --- a/docs/Phaser.Point.html +++ b/docs/Phaser.Point.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,8417 +550,7 @@ Point -

    The Point object represents a location in a two-dimensional coordinate system, -where x represents the horizontal axis and y represents the vertical axis. -The following code creates a point at (0,0): -var myPoint = new Phaser.Point(); -You can also use them as 2D Vectors and you'll find different vector related methods in this class.

    - - - -
    -
    - - - - -
    -

    new Point()

    - - -
    -
    - - - - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - - - -
    - - -
    - - - - - - - - - - - - -

    Members

    - -
    - -
    -

    x

    - - -
    -
    - - - - - -
    - - -
    Properties:
    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    x - - -number - - - -

    The x value of the point.

    -
    - - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - -
    - - - -
    -

    y

    - - -
    -
    - - - - - -
    - - -
    Properties:
    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    y - - -number - - - -

    The y value of the point.

    -
    - - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - -
    - -
    - - - -

    Methods

    - -
    - -
    -

    <static> add(a, b, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Adds the coordinates of two points together to create a new point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The first Point object.

    b - - -Phaser.Point - - - - - - - - - -

    The second Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> angle(a, b) → {number}

    - - -
    -
    - - -
    -

    Returns the angle between two Point objects.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    a - - -Phaser.Point - - - -

    The first Point object.

    b - - -Phaser.Point - - - -

    The second Point object.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The angle between the two Points.

    -
    - - - -
    -
    - Type -
    -
    - -number - - -
    -
    - - - - - -
    - - - -
    -

    <static> angleSq(a, b) → {number}

    - - -
    -
    - - -
    -

    Returns the angle squared between two Point objects.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    a - - -Phaser.Point - - - -

    The first Point object.

    b - - -Phaser.Point - - - -

    The second Point object.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The angle squared between the two Points.

    -
    - - - -
    -
    - Type -
    -
    - -number - - -
    -
    - - - - - -
    - - - -
    -

    <static> centroid(points, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Calculates centroid (or midpoint) from an array of points. If only one point is provided, that point is returned.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    points - - -Phaser.Point[] - - - - - - - - - -

    The array of one or more points.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> distance(a, b, round) → {number}

    - - -
    -
    - - -
    -

    Returns the distance of this Point object to the given object (can be a Circle, Point or anything with x/y properties).

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -object - - - - - - - - - -

    The target object. Must have visible x and y properties that represent the center of the object.

    b - - -object - - - - - - - - - -

    The target object. Must have visible x and y properties that represent the center of the object.

    round - - -boolean - - - - - - <optional>
    - - - - - -

    Round the distance to the nearest integer (default false).

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The distance between this Point object and the destination Point object.

    -
    - - - -
    -
    - Type -
    -
    - -number - - -
    -
    - - - - - -
    - - - -
    -

    <static> divide(a, b, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Divides the coordinates of two points to create a new point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The first Point object.

    b - - -Phaser.Point - - - - - - - - - -

    The second Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> equals(a, b) → {boolean}

    - - -
    -
    - - -
    -

    Determines whether the two given Point objects are equal. They are considered equal if they have the same x and y values.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    a - - -Phaser.Point - - - -

    The first Point object.

    b - - -Phaser.Point - - - -

    The second Point object.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    A value of true if the Points are equal, otherwise false.

    -
    - - - -
    -
    - Type -
    -
    - -boolean - - -
    -
    - - - - - -
    - - - -
    -

    <static> interpolate(a, b, f, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Interpolates the two given Points, based on the f value (between 0 and 1) and returns a new Point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The first Point object.

    b - - -Phaser.Point - - - - - - - - - -

    The second Point object.

    f - - -number - - - - - - - - - -

    The level of interpolation between the two points. Indicates where the new point will be, along the line between pt1 and pt2. If f=1, pt1 is returned; if f=0, pt2 is returned.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> multiply(a, b, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Multiplies the coordinates of two points to create a new point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The first Point object.

    b - - -Phaser.Point - - - - - - - - - -

    The second Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> multiplyAdd(a, b, s, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Adds two 2D Points together and multiplies the result by the given scalar.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The first Point object.

    b - - -Phaser.Point - - - - - - - - - -

    The second Point object.

    s - - -number - - - - - - - - - -

    The scaling value.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> negative(a, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Creates a negative Point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The first Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> normalize(a, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Normalize (make unit length) a Point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> normalRightHand(a, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Right-hand normalize (make unit length) a Point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> perp(a, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Return a perpendicular vector (90 degrees rotation)

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> project(a, b, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Project two Points onto another Point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The first Point object.

    b - - -Phaser.Point - - - - - - - - - -

    The second Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> projectUnit(a, b, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Project two Points onto a Point of unit length.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The first Point object.

    b - - -Phaser.Point - - - - - - - - - -

    The second Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> rotate(a, x, y, angle, asDegrees, distance) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Rotates a Point around the x/y coordinates given to the desired angle.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDefaultDescription
    a - - -Phaser.Point - - - - - - - - - - - -

    The Point object to rotate.

    x - - -number - - - - - - - - - - - -

    The x coordinate of the anchor point

    y - - -number - - - - - - - - - - - -

    The y coordinate of the anchor point

    angle - - -number - - - - - - - - - - - -

    The angle in radians (unless asDegrees is true) to rotate the Point to.

    asDegrees - - -boolean - - - - - - <optional>
    - - - - - -
    - - false - -

    Is the given rotation in radians (false) or degrees (true)?

    distance - - -number - - - - - - <optional>
    - - - - - -
    - -

    An optional distance constraint between the Point and the anchor.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The modified point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> rperp(a, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Return a perpendicular vector (-90 degrees rotation)

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    <static> subtract(a, b, out) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Subtracts the coordinates of two points to create a new point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    a - - -Phaser.Point - - - - - - - - - -

    The first Point object.

    b - - -Phaser.Point - - - - - - - - - -

    The second Point object.

    out - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point to store the value in, if not supplied a new Point object will be created.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    add(x, y) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Adds the given x and y values to this Point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    x - - -number - - - -

    The value to add to Point.x.

    y - - -number - - - -

    The value to add to Point.y.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object. Useful for chaining method calls.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    angle(a, asDegrees) → {number}

    - - -
    -
    - - -
    -

    Returns the angle between this Point object and another object with public x and y properties.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDefaultDescription
    a - - -Phaser.Point -| - -any - - - - - - - - - - - -

    The object to get the angle from this Point to.

    asDegrees - - -boolean - - - - - - <optional>
    - - - - - -
    - - false - -

    Is the given angle in radians (false) or degrees (true)?

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The angle between the two objects.

    -
    - - - -
    -
    - Type -
    -
    - -number - - -
    -
    - - - - - -
    - - - -
    -

    angleSq(a) → {number}

    - - -
    -
    - - -
    -

    Returns the angle squared between this Point object and another object with public x and y properties.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    a - - -Phaser.Point -| - -any - - - -

    The object to get the angleSq from this Point to.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The angleSq between the two objects.

    -
    - - - -
    -
    - Type -
    -
    - -number - - -
    -
    - - - - - -
    - - - -
    -

    clamp(min, max) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Clamps this Point object values to be between the given min and max.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    min - - -number - - - -

    The minimum value to clamp this Point to.

    max - - -number - - - -

    The maximum value to clamp this Point to.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    clampX(min, max) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Clamps the x value of this Point to be between the given min and max.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    min - - -number - - - -

    The minimum value to clamp this Point to.

    max - - -number - - - -

    The maximum value to clamp this Point to.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    clampY(min, max) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Clamps the y value of this Point to be between the given min and max

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    min - - -number - - - -

    The minimum value to clamp this Point to.

    max - - -number - - - -

    The maximum value to clamp this Point to.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    clone(output) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Creates a copy of the given Point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    output - - -Phaser.Point - - - - - - <optional>
    - - - - - -

    Optional Point object. If given the values will be set into this object, otherwise a brand new Point object will be created and returned.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The new Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    copyFrom(source) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Copies the x and y properties from any given object to this Point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    source - - -any - - - -

    The object to copy from.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    copyTo(dest) → {Object}

    - - -
    -
    - - -
    -

    Copies the x and y properties from this Point to any given object.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    dest - - -any - - - -

    The object to copy to.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The dest object.

    -
    - - - -
    -
    - Type -
    -
    - -Object - - -
    -
    - - - - - -
    - - - -
    -

    cross(a) → {number}

    - - -
    -
    - - -
    -

    The cross product of this and another Point object.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    a - - -Phaser.Point - - - -

    The Point object to get the cross product combined with this Point.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The result.

    -
    - - - -
    -
    - Type -
    -
    - -number - - -
    -
    - - - - - -
    - - - -
    -

    distance(dest, round) → {number}

    - - -
    -
    - - -
    -

    Returns the distance of this Point object to the given object (can be a Circle, Point or anything with x/y properties)

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    dest - - -object - - - - - - - - - -

    The target object. Must have visible x and y properties that represent the center of the object.

    round - - -boolean - - - - - - <optional>
    - - - - - -

    Round the distance to the nearest integer (default false).

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The distance between this Point object and the destination Point object.

    -
    - - - -
    -
    - Type -
    -
    - -number - - -
    -
    - - - - - -
    - - - -
    -

    divide(x, y) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Divides Point.x and Point.y by the given x and y values.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    x - - -number - - - -

    The value to divide Point.x by.

    y - - -number - - - -

    The value to divide Point.x by.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object. Useful for chaining method calls.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    dot(a) → {number}

    - - -
    -
    - - -
    -

    The dot product of this and another Point object.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    a - - -Phaser.Point - - - -

    The Point object to get the dot product combined with this Point.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The result.

    -
    - - - -
    -
    - Type -
    -
    - -number - - -
    -
    - - - - - -
    - - - -
    -

    equals(a) → {boolean}

    - - -
    -
    - - -
    -

    Determines whether the given objects x/y values are equal to this Point object.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    a - - -Phaser.Point -| - -any - - - -

    The object to compare with this Point.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    A value of true if the x and y points are equal, otherwise false.

    -
    - - - -
    -
    - Type -
    -
    - -boolean - - -
    -
    - - - - - -
    - - - -
    -

    getMagnitude() → {number}

    - - -
    -
    - - -
    -

    Calculates the length of the Point object.

    -
    - - - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The length of the Point.

    -
    - - - -
    -
    - Type -
    -
    - -number - - -
    -
    - - - - - -
    - - - -
    -

    getMagnitudeSq() → {number}

    - - -
    -
    - - -
    -

    Calculates the length squared of the Point object.

    -
    - - - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The length ^ 2 of the Point.

    -
    - - - -
    -
    - Type -
    -
    - -number - - -
    -
    - - - - - -
    - - - -
    -

    invert() → {Phaser.Point}

    - - -
    -
    - - -
    -

    Inverts the x and y values of this Point

    -
    - - - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    isZero() → {boolean}

    - - -
    -
    - - -
    -

    Determine if this point is at 0,0.

    -
    - - - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    True if this Point is 0,0, otherwise false.

    -
    - - - -
    -
    - Type -
    -
    - -boolean - - -
    -
    - - - - - -
    - - - -
    -

    multiply(x, y) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Multiplies Point.x and Point.y by the given x and y values. Sometimes known as Scale.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    x - - -number - - - -

    The value to multiply Point.x by.

    y - - -number - - - -

    The value to multiply Point.x by.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object. Useful for chaining method calls.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    normalize() → {Phaser.Point}

    - - -
    -
    - - -
    -

    Alters the Point object so that its length is 1, but it retains the same direction.

    -
    - - - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    normalRightHand() → {Phaser.Point}

    - - -
    -
    - - -
    -

    Right-hand normalize (make unit length) this Point.

    -
    - - - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    perp() → {Phaser.Point}

    - - -
    -
    - - -
    -

    Make this Point perpendicular (90 degrees rotation)

    -
    - - - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    rotate(x, y, angle, asDegrees, distance) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Rotates this Point around the x/y coordinates given to the desired angle.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    x - - -number - - - - - - - - - -

    The x coordinate of the anchor point.

    y - - -number - - - - - - - - - -

    The y coordinate of the anchor point.

    angle - - -number - - - - - - - - - -

    The angle in radians (unless asDegrees is true) to rotate the Point to.

    asDegrees - - -boolean - - - - - - - - - -

    Is the given rotation in radians (false) or degrees (true)?

    distance - - -number - - - - - - <optional>
    - - - - - -

    An optional distance constraint between the Point and the anchor.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    The modified point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    rperp() → {Phaser.Point}

    - - -
    -
    - - -
    -

    Make this Point perpendicular (-90 degrees rotation)

    -
    - - - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    set(x, y) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Sets the x and y values of this Point object to the given values. -If you omit the y value then the x value will be applied to both, for example: -Point.setTo(2) is the same as Point.setTo(2, 2)

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    x - - -number - - - - - - - - - -

    The horizontal value of this point.

    y - - -number - - - - - - <optional>
    - - - - - -

    The vertical value of this point. If not given the x value will be used in its place.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object. Useful for chaining method calls.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    setMagnitude(magnitude) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Alters the length of the Point without changing the direction.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    magnitude - - -number - - - -

    The desired magnitude of the resulting Point.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    setTo(x, y) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Sets the x and y values of this Point object to the given values. -If you omit the y value then the x value will be applied to both, for example: -Point.setTo(2) is the same as Point.setTo(2, 2)

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeArgumentDescription
    x - - -number - - - - - - - - - -

    The horizontal value of this point.

    y - - -number - - - - - - <optional>
    - - - - - -

    The vertical value of this point. If not given the x value will be used in its place.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object. Useful for chaining method calls.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    subtract(x, y) → {Phaser.Point}

    - - -
    -
    - - -
    -

    Subtracts the given x and y values from this Point.

    -
    - - - - - - - -
    Parameters:
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    NameTypeDescription
    x - - -number - - - -

    The value to subtract from Point.x.

    y - - -number - - - -

    The value to subtract from Point.y.

    - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    This Point object. Useful for chaining method calls.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Point - - -
    -
    - - - - - -
    - - - -
    -

    toString() → {string}

    - - -
    -
    - - -
    -

    Returns a string representation of this object.

    -
    - - - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Source:
    -
    - - - - - - - -
    - - - - - - - - - - - -
    Returns:
    - - -
    -

    A string representation of the instance.

    -
    - - - -
    -
    - Type -
    -
    - -string - - -
    -
    - - - - - -
    - -
    - - - - - -
    - - - - - - - -

    Class: Point

    -
    - -
    -

    - Phaser. - - Point -

    +

    Phaser.Point

    @@ -8971,7 +569,10 @@ If you omit the y value then the x value will be appli
    -

    Creates a new Point object. If you pass no parameters a Point is created set to (0, 0).

    +

    A Point object represents a location in a two-dimensional coordinate system, where x represents the horizontal axis and y represents the vertical axis. +The following code creates a point at (0,0): +var myPoint = new Phaser.Point(); +You can also use them as 2D Vectors and you'll find different vector related methods in this class.

    @@ -9112,7 +713,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -9240,7 +841,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -9342,7 +943,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -9530,7 +1131,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -9694,7 +1295,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -9858,7 +1459,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -10042,7 +1643,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -10257,7 +1858,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -10472,7 +2073,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -10636,7 +2237,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -10882,7 +2483,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -11097,7 +2698,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -11343,7 +2944,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -11527,7 +3128,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -11711,7 +3312,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -11895,7 +3496,243 @@ If you omit the y value then the x value will be appli
    Source:
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    The new Point object.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.Point + + +
    +
    + + + + + + + + + +
    +

    <static> parse(obj, xProp, yProp) → {Phaser.Point}

    + + +
    +
    + + +
    +

    Parses an object for x and/or y properties and returns a new Phaser.Point with matching values. +If the object doesn't contain those properties a Point with x/y of zero will be returned.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    obj + + +Object + + + + + + + + + + + +

    The object to parse.

    xProp + + +string + + + + + + <optional>
    + + + + + +
    + + 'x' + +

    The property used to set the Point.x value.

    yProp + + +string + + + + + + <optional>
    + + + + + +
    + + 'y' + +

    The property used to set the Point.y value.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -12079,7 +3916,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -12294,7 +4131,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -12509,7 +4346,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -12847,7 +4684,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -13031,7 +4868,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -13246,7 +5083,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -13410,7 +5247,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -13609,7 +5446,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -13753,7 +5590,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -13917,7 +5754,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -14081,7 +5918,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -14245,7 +6082,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -14398,7 +6235,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -14539,7 +6376,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -14680,7 +6517,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -14821,7 +6658,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -15005,7 +6842,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -15169,7 +7006,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -15310,7 +7147,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -15454,7 +7291,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -15546,7 +7383,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -15638,7 +7475,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -15730,7 +7567,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -15822,7 +7659,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -15986,7 +7823,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -16078,7 +7915,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -16170,7 +8007,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -16262,7 +8099,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -16539,7 +8376,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -16631,7 +8468,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -16817,7 +8654,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -16958,7 +8795,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -17144,7 +8981,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -17308,7 +9145,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -17400,7 +9237,7 @@ If you omit the y value then the x value will be appli
    Source:
    @@ -17474,7 +9311,7 @@ If you omit the y value then the x value will be appli Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:36 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:04 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Pointer.html b/docs/Phaser.Pointer.html index 18acb6e5f..c1d6f3fa4 100644 --- a/docs/Phaser.Pointer.html +++ b/docs/Phaser.Pointer.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Pointer -

    A Pointer object is used by the Mouse, Touch and MSPoint managers and represents a single finger on the touch screen.

    +

    Phaser.Pointer

    @@ -561,7 +569,7 @@
    -

    Phaser - Pointer constructor.

    +

    A Pointer object is used by the Mouse, Touch and MSPoint managers and represents a single finger on the touch screen.

    @@ -666,7 +674,7 @@
    Source:
    @@ -797,7 +805,7 @@
    Source:
    @@ -902,7 +910,7 @@
    Source:
    @@ -1009,7 +1017,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -1111,7 +1119,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -1213,7 +1221,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -1318,7 +1326,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -1424,7 +1432,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -1529,7 +1537,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -1631,7 +1639,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -1733,7 +1741,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -1838,7 +1846,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -1943,7 +1951,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -2048,7 +2056,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -2153,7 +2161,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -2258,7 +2266,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -2363,7 +2371,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -2465,7 +2473,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -2567,7 +2575,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -2669,7 +2677,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -2774,7 +2782,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -2876,7 +2884,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -2978,7 +2986,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -3080,7 +3088,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -3185,7 +3193,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -3290,7 +3298,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -3395,7 +3403,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -3497,7 +3505,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -3599,7 +3607,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -3704,7 +3712,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -3809,7 +3817,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -3914,7 +3922,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -4019,7 +4027,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -4124,7 +4132,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -4226,7 +4234,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -4328,7 +4336,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -4434,7 +4442,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -4540,7 +4548,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -4642,7 +4650,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -4744,7 +4752,7 @@ The Circle size is 44px (Apples recommended "finger tip" size).

    Source:
    @@ -4872,7 +4880,7 @@ If you wish to check if the Pointer was pressed down just once then see the Spri
    Source:
    @@ -5027,7 +5035,7 @@ If you wish to check if the Pointer was released just once then see the Sprite.e
    Source:
    @@ -5174,7 +5182,7 @@ If you wish to check if the Pointer was released just once then see the Sprite.e
    Source:
    @@ -5353,7 +5361,7 @@ If you wish to check if the Pointer was released just once then see the Sprite.e
    Source:
    @@ -5491,7 +5499,7 @@ If you wish to check if the Pointer was released just once then see the Sprite.e
    Source:
    @@ -5583,7 +5591,7 @@ If you wish to check if the Pointer was released just once then see the Sprite.e
    Source:
    @@ -5652,7 +5660,7 @@ If you wish to check if the Pointer was released just once then see the Sprite.e
    Source:
    @@ -5770,7 +5778,7 @@ If you wish to check if the Pointer was released just once then see the Sprite.e
    Source:
    @@ -5894,7 +5902,7 @@ If you wish to check if the Pointer was released just once then see the Sprite.e
    Source:
    @@ -5963,7 +5971,7 @@ If you wish to check if the Pointer was released just once then see the Sprite.e
    Source:
    @@ -6014,7 +6022,7 @@ If you wish to check if the Pointer was released just once then see the Sprite.e Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:36 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:04 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Polygon.html b/docs/Phaser.Polygon.html index 62d2a9404..a9abfb26b 100644 --- a/docs/Phaser.Polygon.html +++ b/docs/Phaser.Polygon.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Polygon -

    The polygon represents a list of orderded points in space

    +

    Phaser.Polygon

    @@ -649,7 +657,7 @@ arguments passed can be flat x,y values e.g. new Phaser.Polygon(x,y, x,y,
    Source:
    @@ -785,7 +793,7 @@ Sets and modifies the points of this polygon.

    Source:
    @@ -887,7 +895,7 @@ Sets and modifies the points of this polygon.

    Source:
    @@ -1014,7 +1022,7 @@ This is a deep clone, the resulting copy contains new Phaser.Point objects

    Source:
    @@ -1178,7 +1186,7 @@ This is a deep clone, the resulting copy contains new Phaser.Point objects

    Source:
    @@ -1252,7 +1260,7 @@ This is a deep clone, the resulting copy contains new Phaser.Point objects

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:36 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:04 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.QuadTree.html b/docs/Phaser.QuadTree.html index 859459bab..b5d474289 100644 --- a/docs/Phaser.QuadTree.html +++ b/docs/Phaser.QuadTree.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,9 +550,7 @@ QuadTree -

    A QuadTree implementation. The original code was a conversion of the Java code posted to GameDevTuts. -However I've tweaked it massively to add node indexing, removed lots of temp. var creation and significantly increased performance as a result. -Original version at https://github.com/timohausmann/quadtree-js/

    +

    Phaser.QuadTree

    @@ -563,7 +569,9 @@ Original version at https @@ -883,7 +891,7 @@ Original version at https
    Source:
    @@ -1011,7 +1019,7 @@ Original version at https
    Source:
    @@ -1113,7 +1121,7 @@ Original version at https
    Source:
    @@ -1218,7 +1226,7 @@ Original version at https
    Source:
    @@ -1323,7 +1331,7 @@ Original version at https
    Source:
    @@ -1425,7 +1433,7 @@ Original version at https
    Source:
    @@ -1527,7 +1535,7 @@ Original version at https
    Source:
    @@ -1592,7 +1600,7 @@ Original version at https
    Source:
    @@ -1713,7 +1721,7 @@ Original version at https
    Source:
    @@ -1857,7 +1865,7 @@ Original version at https
    Source:
    @@ -1975,7 +1983,7 @@ Original version at https
    Source:
    @@ -2096,7 +2104,7 @@ Original version at https
    Source:
    @@ -2452,7 +2460,7 @@ Original version at https
    Source:
    @@ -2573,7 +2581,7 @@ Original version at https
    Source:
    @@ -2667,7 +2675,7 @@ Original version at https
    Source:
    @@ -2718,7 +2726,7 @@ Original version at https Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:36 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:04 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.RandomDataGenerator.html b/docs/Phaser.RandomDataGenerator.html index 278dd0fd2..f85ed0a39 100644 --- a/docs/Phaser.RandomDataGenerator.html +++ b/docs/Phaser.RandomDataGenerator.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,9 +550,7 @@ RandomDataGenerator -

    An extremely useful repeatable random data generator. Access it via Phaser.Game.rnd -Based on Nonsense by Josh Faul https://github.com/jocafa/Nonsense. -Random number generator from http://baagoe.org/en/wiki/Better_random_numbers_for_javascript

    +

    Phaser.RandomDataGenerator

    @@ -555,7 +561,7 @@ Random number generator from new RandomDataGenerator(seeds) +

    new RandomDataGenerator(seeds)

    @@ -563,7 +569,9 @@ Random number generator from
    -

    Phaser.RandomDataGenerator constructor.

    +

    An extremely useful repeatable random data generator. +Based on Nonsense by Josh Faul https://github.com/jocafa/Nonsense. +Random number generator from http://baagoe.org/en/wiki/Better_random_numbers_for_javascript

    @@ -585,6 +593,8 @@ Random number generator from + + + <optional>
    + + + + + + + - +

    An array of values to use as the seed.

    @@ -645,7 +665,7 @@ Random number generator from
    Source:
    @@ -732,7 +752,7 @@ Random number generator from Source:
    @@ -897,7 +917,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -989,7 +1009,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -1081,7 +1101,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -1245,7 +1265,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -1337,7 +1357,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -1478,7 +1498,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -1570,7 +1590,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -1734,7 +1754,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -1875,7 +1895,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -2016,7 +2036,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -2108,7 +2128,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -2249,7 +2269,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Source:
    @@ -2323,7 +2343,7 @@ This method is an alias for RandomDataGenerator.integerInRange.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:37 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:05 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Rectangle.html b/docs/Phaser.Rectangle.html index 5cbc2bcdf..423560c00 100644 --- a/docs/Phaser.Rectangle.html +++ b/docs/Phaser.Rectangle.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -553,7 +561,7 @@
    -

    new Rectangle(x, y, width, height) → {Phaser.Rectangle}

    +

    new Rectangle(x, y, width, height)

    @@ -561,7 +569,8 @@
    -

    Creates a new Rectangle object with the top-left corner specified by the x and y parameters and with the specified width and height parameters. If you call this function without parameters, a Rectangle with x, y, width, and height properties set to 0 is created.

    +

    Creates a new Rectangle object with the top-left corner specified by the x and y parameters and with the specified width and height parameters. +If you call this function without parameters, a Rectangle with x, y, width, and height properties set to 0 is created.

    @@ -733,29 +742,6 @@ -
    Returns:
    - - -
    -

    This Rectangle object.

    -
    - - - -
    -
    - Type -
    -
    - -Phaser.Rectangle - - -
    -
    - - -
    @@ -5358,6 +5344,190 @@ This method checks the x, y, width, and height properties of the Rectangles.

    + + + + +
    +

    aabb(points, out) → {Phaser.Rectangle}

    + + +
    +
    + + +
    +

    Calculates the Axis Aligned Bounding Box (or aabb) from an array of points.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDescription
    points + + +Phaser.Point[] + + + + + + + + + +

    The array of one or more points.

    out + + +Phaser.Rectangle + + + + + + <optional>
    + + + + + +

    Optional Rectangle to store the value in, if not supplied a new Rectangle object will be created.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    The new Rectangle object.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.Rectangle + + +
    +
    + + + + +
    @@ -8237,7 +8407,7 @@ This method checks the x, y, width, and height properties of the Rectangles.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:37 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:05 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.RenderTexture.html b/docs/Phaser.RenderTexture.html index 15e7fc0e4..9cebd67e7 100644 --- a/docs/Phaser.RenderTexture.html +++ b/docs/Phaser.RenderTexture.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -851,7 +859,7 @@ render them down into a single quad (on WebGL) which can then be used to texture
    Source:
    @@ -880,6 +888,12 @@ render them down into a single quad (on WebGL) which can then be used to texture +

    Extends

    + +
      +
    • PIXI.RenderTexture
    • +
    + @@ -979,7 +993,7 @@ render them down into a single quad (on WebGL) which can then be used to texture
    Source:
    @@ -1081,7 +1095,7 @@ render them down into a single quad (on WebGL) which can then be used to texture
    Source:
    @@ -1183,7 +1197,7 @@ render them down into a single quad (on WebGL) which can then be used to texture
    Source:
    @@ -1355,7 +1369,7 @@ render them down into a single quad (on WebGL) which can then be used to texture
    Source:
    @@ -1554,7 +1568,7 @@ render them down into a single quad (on WebGL) which can then be used to texture
    Source:
    @@ -1695,7 +1709,7 @@ render them down into a single quad (on WebGL) which can then be used to texture
    Source:
    @@ -1746,7 +1760,7 @@ render them down into a single quad (on WebGL) which can then be used to texture Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:37 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:05 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.RequestAnimationFrame.html b/docs/Phaser.RequestAnimationFrame.html index c056743be..8550fe155 100644 --- a/docs/Phaser.RequestAnimationFrame.html +++ b/docs/Phaser.RequestAnimationFrame.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1532,7 +1540,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:37 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:05 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.RetroFont.html b/docs/Phaser.RetroFont.html index e8d7b1115..fcdcc1754 100644 --- a/docs/Phaser.RetroFont.html +++ b/docs/Phaser.RetroFont.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -560,6 +568,11 @@
    +
    +

    A Retro Font is similar to a BitmapFont, in that it uses a texture to render the text. However unlike a BitmapFont every character in a RetroFont +is the same size. This makes it similar to a sprite sheet. You typically find font sheets like this from old 8/16-bit games and demos.

    +
    + @@ -988,7 +1001,7 @@
    Source:
    @@ -1084,7 +1097,7 @@
    Source:
    @@ -1148,7 +1161,7 @@
    Source:
    @@ -1212,7 +1225,7 @@
    Source:
    @@ -1276,7 +1289,7 @@
    Source:
    @@ -1340,7 +1353,7 @@
    Source:
    @@ -1404,7 +1417,7 @@
    Source:
    @@ -1468,7 +1481,7 @@
    Source:
    @@ -1532,7 +1545,7 @@
    Source:
    @@ -1596,7 +1609,7 @@
    Source:
    @@ -1660,7 +1673,7 @@
    Source:
    @@ -1724,7 +1737,7 @@
    Source:
    @@ -1788,7 +1801,7 @@
    Source:
    @@ -1852,7 +1865,7 @@
    Source:
    @@ -1916,7 +1929,7 @@
    Source:
    @@ -2018,7 +2031,7 @@
    Source:
    @@ -2123,7 +2136,7 @@
    Source:
    @@ -2225,7 +2238,7 @@
    Source:
    @@ -2327,7 +2340,7 @@
    Source:
    @@ -2429,7 +2442,7 @@
    Source:
    @@ -2531,7 +2544,7 @@
    Source:
    @@ -2633,7 +2646,7 @@
    Source:
    @@ -2738,7 +2751,7 @@
    Source:
    @@ -2843,7 +2856,7 @@
    Source:
    @@ -2950,7 +2963,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -3052,7 +3065,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -3154,7 +3167,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -3261,7 +3274,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -3368,7 +3381,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -3473,7 +3486,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -3575,7 +3588,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -3677,7 +3690,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -3779,7 +3792,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -3881,7 +3894,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -3946,7 +3959,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -4015,7 +4028,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -4226,7 +4239,7 @@ Used by getLine and getMultiLine

    Source:
    @@ -4364,7 +4377,7 @@ Used by getLine and getMultiLine

    Source:
    @@ -4568,7 +4581,7 @@ Used by getLine and getMultiLine

    Source:
    @@ -4772,7 +4785,7 @@ Used by getLine and getMultiLine

    Source:
    @@ -4918,7 +4931,7 @@ Used by getLine and getMultiLine

    Source:
    @@ -5092,7 +5105,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -5421,7 +5434,7 @@ If text is wider than the width specified it will be cropped off.

    Source:
    @@ -5600,7 +5613,7 @@ So if the current offsetY is 8 and you want it to start rendering from y16 you w
    Source:
    @@ -5651,7 +5664,7 @@ So if the current offsetY is 8 and you want it to start rendering from y16 you w Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:37 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:05 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Rope.html b/docs/Phaser.Rope.html index 6c5dad3ad..d72f1b278 100644 --- a/docs/Phaser.Rope.html +++ b/docs/Phaser.Rope.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -794,7 +802,7 @@ Please note that Ropes, as with normal Sprites, have no input handler or physics
    Source:
    @@ -823,6 +831,12 @@ Please note that Ropes, as with normal Sprites, have no input handler or physics +

    Extends

    + +
      +
    • Pixi.Rope
    • +
    + @@ -928,7 +942,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1030,7 +1044,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1141,7 +1155,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -1263,7 +1277,7 @@ If you need a different result then adjust or re-create the Body shape offsets m
    Source:
    @@ -1365,7 +1379,7 @@ If you need a different result then adjust or re-create the Body shape offsets m
    Source:
    @@ -1476,7 +1490,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1578,7 +1592,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1680,7 +1694,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1788,7 +1802,7 @@ Setting Rope.exists to true will re-add the Body to the physics world (if it has
    Source:
    @@ -1896,7 +1910,7 @@ So if this Rope was in a Group that has x: 200, then this will be added to the c
    Source:
    @@ -1998,7 +2012,7 @@ So if this Rope was in a Group that has x: 200, then this will be added to the c
    Source:
    @@ -2100,7 +2114,7 @@ So if this Rope was in a Group that has x: 200, then this will be added to the c
    Source:
    @@ -2202,7 +2216,7 @@ So if this Rope was in a Group that has x: 200, then this will be added to the c
    Source:
    @@ -2307,7 +2321,7 @@ So if this Rope was in a Group that has x: 200, then this will be added to the c
    Source:
    @@ -2414,7 +2428,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2525,7 +2539,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2627,7 +2641,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2733,7 +2747,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2835,7 +2849,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2941,7 +2955,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3043,7 +3057,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3149,7 +3163,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3255,7 +3269,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3357,7 +3371,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3492,7 +3506,7 @@ and nulls its reference to game, freeing it up for garbage collection.

    Source:
    @@ -3646,7 +3660,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -3898,7 +3912,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -3990,7 +4004,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -4059,7 +4073,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -4202,7 +4216,7 @@ If the Rope has a physics body that too is reset.

    Source:
    @@ -4332,7 +4346,7 @@ This is primarily an internal method used by Rope.loadTexture, although you may
    Source:
    @@ -4401,7 +4415,7 @@ This is primarily an internal method used by Rope.loadTexture, although you may
    Source:
    @@ -4452,7 +4466,7 @@ This is primarily an internal method used by Rope.loadTexture, although you may Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:38 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:06 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.ScaleManager.html b/docs/Phaser.ScaleManager.html index 529088520..f0533a13b 100644 --- a/docs/Phaser.ScaleManager.html +++ b/docs/Phaser.ScaleManager.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -6918,7 +6926,7 @@ Please note that this needs to be supported by the web browser and isn't the sam Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:38 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:06 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Signal.html b/docs/Phaser.Signal.html index ec16bc366..99a567aa4 100644 --- a/docs/Phaser.Signal.html +++ b/docs/Phaser.Signal.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Signal -

    A Signal is used for object communication via a custom broadcaster instead of Events.

    +

    Phaser.Signal

    @@ -560,6 +568,10 @@
    +
    +

    A Signal is used for object communication via a custom broadcaster instead of Events.

    +
    + @@ -580,13 +592,6 @@ -
    Author:
    -
    -
      -
    • Miller Medeiros http://millermedeiros.github.com/js-signals/
    • -
    -
    - @@ -597,7 +602,7 @@
    Source:
    @@ -733,7 +738,7 @@ IMPORTANT: Setting this property during a dispatch will only affect the next dis
    Source:
    @@ -841,7 +846,7 @@ already dispatched before.

    Source:
    @@ -1031,7 +1036,7 @@ already dispatched before.

    Source:
    @@ -1248,7 +1253,7 @@ already dispatched before.

    Source:
    @@ -1401,7 +1406,7 @@ already dispatched before.

    Source:
    @@ -1518,7 +1523,7 @@ already dispatched before.

    Source:
    @@ -1588,7 +1593,7 @@ IMPORTANT: calling any method on the signal instance after calling dispose will
    Source:
    @@ -1657,7 +1662,7 @@ IMPORTANT: calling any method on the signal instance after calling dispose will
    Source:
    @@ -1733,7 +1738,7 @@ IMPORTANT: calling any method on the signal instance after calling dispose will
    Source:
    @@ -1826,7 +1831,7 @@ IMPORTANT: should be called only during signal dispatch, calling it before/after
    Source:
    @@ -1994,7 +1999,7 @@ IMPORTANT: should be called only during signal dispatch, calling it before/after
    Source:
    @@ -2178,7 +2183,7 @@ IMPORTANT: should be called only during signal dispatch, calling it before/after
    Source:
    @@ -2339,7 +2344,7 @@ IMPORTANT: should be called only during signal dispatch, calling it before/after
    Source:
    @@ -2404,7 +2409,7 @@ IMPORTANT: should be called only during signal dispatch, calling it before/after
    Source:
    @@ -2478,7 +2483,7 @@ IMPORTANT: should be called only during signal dispatch, calling it before/after Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:38 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:06 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.SignalBinding.html b/docs/Phaser.SignalBinding.html index 82325a890..93431e5cd 100644 --- a/docs/Phaser.SignalBinding.html +++ b/docs/Phaser.SignalBinding.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,9 +550,7 @@ SignalBinding -

    Object that represents a binding between a Signal and a listener function. -This is an internal constructor and shouldn't be created directly. -Inspired by Joa Ebert AS3 SignalBinding and Robert Penner's Slot classes.

    +

    Phaser.SignalBinding

    @@ -562,6 +568,12 @@ Inspired by Joa Ebert AS3 SignalBinding and Robert Penner's Slot classes.

    +
    +

    Object that represents a binding between a Signal and a listener function. +This is an internal constructor and shouldn't be created directly. +Inspired by Joa Ebert AS3 SignalBinding and Robert Penner's Slot classes.

    +
    + @@ -769,13 +781,6 @@ Inspired by Joa Ebert AS3 SignalBinding and Robert Penner's Slot classes.

    Author: -
    -
      -
    • Miller Medeiros http://millermedeiros.github.com/js-signals/
    • -
    -
    - @@ -1878,7 +1883,7 @@ If binding was added using Signal.addOnce() it will be automaticall Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:38 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:06 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.SinglePad.html b/docs/Phaser.SinglePad.html index bb3d1f410..f5b474288 100644 --- a/docs/Phaser.SinglePad.html +++ b/docs/Phaser.SinglePad.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ SinglePad -

    A single Phaser Gamepad

    +

    Phaser.SinglePad

    @@ -560,6 +568,10 @@
    +
    +

    A single Phaser Gamepad

    +
    + @@ -662,7 +674,7 @@
    Source:
    @@ -790,7 +802,7 @@
    Source:
    @@ -892,7 +904,7 @@
    Source:
    @@ -994,7 +1006,7 @@
    Source:
    @@ -1096,7 +1108,7 @@
    Source:
    @@ -1198,7 +1210,7 @@
    Source:
    @@ -1300,7 +1312,7 @@
    Source:
    @@ -1402,7 +1414,7 @@
    Source:
    @@ -1504,7 +1516,7 @@
    Source:
    @@ -1606,7 +1618,7 @@
    Source:
    @@ -1708,7 +1720,7 @@
    Source:
    @@ -1810,7 +1822,7 @@
    Source:
    @@ -1948,7 +1960,7 @@ onConnectCallback, onDisconnectCallback, onDownCallback, onUpCallback, onAxisCal
    Source:
    @@ -2066,7 +2078,7 @@ onConnectCallback, onDisconnectCallback, onDownCallback, onUpCallback, onAxisCal
    Source:
    @@ -2208,7 +2220,7 @@ analog trigger buttons on the XBOX 360 controller.

    Source:
    @@ -2349,7 +2361,7 @@ analog trigger buttons on the XBOX 360 controller.

    Source:
    @@ -2418,7 +2430,7 @@ analog trigger buttons on the XBOX 360 controller.

    Source:
    @@ -2537,7 +2549,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -2678,7 +2690,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -2819,7 +2831,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -3015,7 +3027,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -3211,7 +3223,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -3303,7 +3315,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -3421,7 +3433,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -3562,7 +3574,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -3703,7 +3715,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -3844,7 +3856,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -3913,7 +3925,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Source:
    @@ -3964,7 +3976,7 @@ The GamepadButton object can then be polled, have events attached to it, etc.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:38 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:06 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Sound.html b/docs/Phaser.Sound.html index 6bc586972..d62ac1e24 100644 --- a/docs/Phaser.Sound.html +++ b/docs/Phaser.Sound.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Sound -

    The Sound class

    +

    Phaser.Sound

    @@ -772,7 +780,7 @@
    Source:
    @@ -815,6 +823,111 @@
    +
    +

    allowMultiple

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    allowMultiple + + +boolean + + + +

    This will allow you to have multiple instances of this Sound playing at once. This is only useful when running under Web Audio, and we recommend you implement a local pooling system to not flood the sound channels.

    +
    + + + + + + + + + + + + + + + + + + +
    Default Value:
    +
    • false
    + + + +
    Source:
    +
    + + + + + + + +
    + + + +
    + + +

    autoplay

    @@ -900,7 +1013,7 @@
    Source:
    @@ -1002,7 +1115,7 @@
    Source:
    @@ -1104,7 +1217,7 @@
    Source:
    @@ -1206,7 +1319,7 @@
    Source:
    @@ -1308,7 +1421,7 @@
    Source:
    @@ -1410,7 +1523,7 @@
    Source:
    @@ -1512,7 +1625,7 @@
    Source:
    @@ -1614,7 +1727,7 @@
    Source:
    @@ -1720,7 +1833,7 @@
    Source:
    @@ -1822,7 +1935,7 @@
    Source:
    @@ -1924,7 +2037,7 @@
    Source:
    @@ -2029,7 +2142,7 @@
    Source:
    @@ -2131,7 +2244,7 @@
    Source:
    @@ -2233,7 +2346,7 @@
    Source:
    @@ -2335,7 +2448,7 @@
    Source:
    @@ -2437,7 +2550,7 @@
    Source:
    @@ -2539,7 +2652,7 @@
    Source:
    @@ -2641,7 +2754,7 @@
    Source:
    @@ -2743,7 +2856,109 @@
    Source:
    + + + + + + + +
    + + + + + + + +
    +

    onFadeComplete

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    onFadeComplete + + +Phaser.Signal + + + +

    The onFadeComplete event is dispatched when this sound finishes fading either in or out.

    +
    + + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -2845,7 +3060,7 @@
    Source:
    @@ -2947,7 +3162,7 @@
    Source:
    @@ -3049,7 +3264,7 @@
    Source:
    @@ -3151,7 +3366,7 @@
    Source:
    @@ -3253,7 +3468,7 @@
    Source:
    @@ -3355,7 +3570,7 @@
    Source:
    @@ -3457,7 +3672,7 @@
    Source:
    @@ -3562,7 +3777,7 @@
    Source:
    @@ -3667,7 +3882,7 @@
    Source:
    @@ -3769,7 +3984,7 @@
    Source:
    @@ -3871,7 +4086,7 @@
    Source:
    @@ -3973,7 +4188,7 @@
    Source:
    @@ -4075,7 +4290,7 @@
    Source:
    @@ -4180,7 +4395,7 @@
    Source:
    @@ -4282,7 +4497,7 @@
    Source:
    @@ -4384,7 +4599,7 @@
    Source:
    @@ -4486,7 +4701,7 @@
    Source:
    @@ -4588,7 +4803,7 @@
    Source:
    @@ -4690,7 +4905,7 @@
    Source:
    @@ -4792,7 +5007,7 @@
    Source:
    @@ -5071,7 +5286,7 @@ This allows you to bundle multiple sounds together into a single audio file and
    Source:
    @@ -5209,7 +5424,327 @@ This allows you to bundle multiple sounds together into a single audio file and
    Source:
    + + + + + + + +
    + + + + + + + + + + + + + +
    + + + +
    +

    fadeIn(duration, loop)

    + + +
    +
    + + +
    +

    Starts this sound playing (or restarts it if already doing so) and sets the volume to zero. +Then increases the volume from 0 to 1 over the duration specified. +At the end of the fade Sound.onFadeComplete is dispatched with this Sound object as the first parameter, +and the final volume (1) as the second parameter.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    duration + + +number + + + + + + <optional>
    + + + + + +
    + + 1000 + +

    The time in milliseconds during which the Sound should fade in.

    loop + + +boolean + + + + + + <optional>
    + + + + + +
    + + false + +

    Should the Sound be set to loop? Note that this doesn't cause the fade to repeat.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + + + +
    + + + +
    +

    fadeOut(duration)

    + + +
    +
    + + +
    +

    Decreases the volume of this Sound from its current value to 0 over the duration specified. +At the end of the fade Sound.onFadeComplete is dispatched with this Sound object as the first parameter, +and the final volume (0) as the second parameter.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    duration + + +number + + + + + + <optional>
    + + + + + +
    + + 1000 + +

    The time in milliseconds during which the Sound should fade out.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -5278,7 +5813,7 @@ This allows you to bundle multiple sounds together into a single audio file and
    Source:
    @@ -5572,7 +6107,7 @@ This allows you to bundle multiple sounds together into a single audio file and
    Source:
    @@ -5713,7 +6248,7 @@ This allows you to bundle multiple sounds together into a single audio file and
    Source:
    @@ -5968,7 +6503,7 @@ This allows you to bundle multiple sounds together into a single audio file and
    Source:
    @@ -6037,7 +6572,7 @@ This allows you to bundle multiple sounds together into a single audio file and
    Source:
    @@ -6155,7 +6690,7 @@ This allows you to bundle multiple sounds together into a single audio file and
    Source:
    @@ -6224,7 +6759,7 @@ This allows you to bundle multiple sounds together into a single audio file and
    Source:
    @@ -6293,7 +6828,7 @@ This allows you to bundle multiple sounds together into a single audio file and
    Source:
    @@ -6344,7 +6879,7 @@ This allows you to bundle multiple sounds together into a single audio file and Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:39 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:07 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.SoundManager.html b/docs/Phaser.SoundManager.html index a0b599904..0e8b79fb9 100644 --- a/docs/Phaser.SoundManager.html +++ b/docs/Phaser.SoundManager.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ SoundManager -

    Phaser Sound Manager.

    +

    Phaser.SoundManager

    @@ -561,8 +569,7 @@
    -

    Sound Manager constructor. -The Sound Manager is responsible for playing back audio via either the Legacy HTML Audio tag or via Web Audio if the browser supports it. +

    The Sound Manager is responsible for playing back audio via either the Legacy HTML Audio tag or via Web Audio if the browser supports it. Note: On Firefox 25+ on Linux if you have media.gstreamer disabled in about:config then it cannot play back mp3 or m4a files. The audio file type and the encoding of those files are extremely important. Not all browsers can play all audio formats. There is a good guide to what's supported here: http://hpr.dogphilosophy.net/test/

    @@ -647,7 +654,7 @@ There is a good guide to what's supported here: Source:
    @@ -778,7 +785,7 @@ There is a good guide to what's supported here: Source:
    @@ -883,7 +890,7 @@ There is a good guide to what's supported here: Source:
    @@ -988,7 +995,7 @@ There is a good guide to what's supported here: Source:
    @@ -1090,7 +1097,7 @@ There is a good guide to what's supported here: Source:
    @@ -1192,7 +1199,7 @@ There is a good guide to what's supported here: Source:
    @@ -1297,7 +1304,7 @@ There is a good guide to what's supported here: Source:
    @@ -1399,7 +1406,7 @@ There is a good guide to what's supported here: Source:
    @@ -1504,7 +1511,7 @@ There is a good guide to what's supported here: Source:
    @@ -1606,7 +1613,7 @@ There is a good guide to what's supported here: Source:
    @@ -1708,7 +1715,7 @@ There is a good guide to what's supported here: Source:
    @@ -1810,7 +1817,7 @@ There is a good guide to what's supported here: Source:
    @@ -2057,7 +2064,7 @@ There is a good guide to what's supported here: Source:
    @@ -2103,6 +2110,147 @@ There is a good guide to what's supported here: addSprite(key) → {Phaser.AudioSprite} + + + +
    + + +
    +

    Adds a new AudioSprite into the SoundManager.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    key + + +string + + + +

    Asset key for the sound.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    The new AudioSprite instance.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.AudioSprite + + +
    +
    + + + + +
    @@ -2149,7 +2297,7 @@ There is a good guide to what's supported here: Source:
    @@ -2310,7 +2458,7 @@ There is a good guide to what's supported here: Source:
    @@ -2379,7 +2527,7 @@ There is a good guide to what's supported here: Source:
    @@ -2448,7 +2596,7 @@ There is a good guide to what's supported here: Source:
    @@ -2660,7 +2808,7 @@ There is a good guide to what's supported here: Source:
    @@ -2801,7 +2949,7 @@ There is a good guide to what's supported here: Source:
    @@ -2943,7 +3091,7 @@ The removed Sounds are destroyed before removal.

    Source:
    @@ -3035,7 +3183,7 @@ The removed Sounds are destroyed before removal.

    Source:
    @@ -3104,7 +3252,7 @@ The removed Sounds are destroyed before removal.

    Source:
    @@ -3173,7 +3321,7 @@ The removed Sounds are destroyed before removal.

    Source:
    @@ -3242,7 +3390,7 @@ The removed Sounds are destroyed before removal.

    Source:
    @@ -3293,7 +3441,7 @@ The removed Sounds are destroyed before removal.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:39 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:07 GMT+0100 (BST) using the DocStrap template.
    diff --git a/docs/Phaser.Sprite.html b/docs/Phaser.Sprite.html index 3c2cab5b0..e6ca668a3 100644 --- a/docs/Phaser.Sprite.html +++ b/docs/Phaser.Sprite.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,10 +550,7 @@ Sprite -

    Create a new Sprite object. Sprites are the lifeblood of your game, used for nearly everything visual.

    -

    At its most basic a Sprite consists of a set of coordinates and a texture that is rendered to the canvas. -They also contain additional properties allowing for physics motion (via Sprite.body), input handling (via Sprite.input), -events (via Sprite.events), animation (via Sprite.animations), camera culling and more. Please see the Examples for use cases.

    +

    Phaser.Sprite

    @@ -563,6 +568,13 @@ events (via Sprite.events), animation (via Sprite.animations), camera culling an
    +
    +

    Sprites are the lifeblood of your game, used for nearly everything visual.

    +

    At its most basic a Sprite consists of a set of coordinates and a texture that is rendered to the canvas. +They also contain additional properties allowing for physics motion (via Sprite.body), input handling (via Sprite.input), +events (via Sprite.events), animation (via Sprite.animations), camera culling and more. Please see the Examples for use cases.

    +
    + @@ -746,7 +758,7 @@ events (via Sprite.events), animation (via Sprite.animations), camera culling an
    Source:
    @@ -883,7 +895,7 @@ events (via Sprite.events), animation (via Sprite.animations), camera culling an
    Source:
    @@ -991,7 +1003,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1093,7 +1105,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1204,7 +1216,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -1326,7 +1338,7 @@ If you need a different result then adjust or re-create the Body shape offsets m
    Source:
    @@ -1428,7 +1440,7 @@ If you need a different result then adjust or re-create the Body shape offsets m
    Source:
    @@ -1539,7 +1551,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1644,7 +1656,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1749,7 +1761,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1855,7 +1867,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1961,7 +1973,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2067,7 +2079,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2169,7 +2181,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2271,7 +2283,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -2379,7 +2391,7 @@ Setting Sprite.exists to true will re-add the Body to the physics world (if it h
    Source:
    @@ -2487,7 +2499,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2589,7 +2601,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2691,7 +2703,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2793,7 +2805,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2895,7 +2907,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3001,7 +3013,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3106,7 +3118,7 @@ So if this Sprite was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3213,7 +3225,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3319,7 +3331,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3430,7 +3442,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3540,7 +3552,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -3642,7 +3654,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -3747,7 +3759,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -3849,7 +3861,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -3951,7 +3963,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4057,7 +4069,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4159,7 +4171,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4261,7 +4273,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4367,7 +4379,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4473,7 +4485,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4575,7 +4587,7 @@ The lifespan is decremented by game.time.elapsed each update, once it reaches ze
    Source:
    @@ -4641,7 +4653,7 @@ bought to the top of that Group, not the entire display list.

    Source:
    @@ -4830,7 +4842,7 @@ A reference to the rectangle is stored in Sprite.cropRect unless the copy<
    Source:
    @@ -4949,7 +4961,7 @@ If health is then taken below or is equal to zero Sprite.kill is ca
    Source:
    @@ -5099,7 +5111,7 @@ and nulls its reference to game, freeing it up for garbage collection.

    Source:
    @@ -5171,7 +5183,7 @@ If you don't need this Sprite any more you should call Sprite.destroy instead.Source:
    @@ -5405,7 +5417,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -5537,7 +5549,7 @@ Therefore it's relatively expensive to use in large quantities (i.e. with lots o
    Source:
    @@ -5812,7 +5824,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -5904,7 +5916,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -5973,7 +5985,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -6206,7 +6218,7 @@ If the Sprite has a physics body that too is reset.

    Source:
    @@ -6286,7 +6298,7 @@ If the Sprite has a physics body that too is reset.

    Source:
    @@ -6426,7 +6438,7 @@ It will dispatch the onRevived event, you can listen to Sprite.events.onRevived
    Source:
    @@ -6556,7 +6568,7 @@ This is primarily an internal method used by Sprite.loadTexture, although you ma
    Source:
    @@ -6626,7 +6638,7 @@ Remember if this Sprite has any children you should call update on them too.

    Source:
    @@ -6696,7 +6708,7 @@ then you need to update the crop frame by calling this method.

    Source:
    @@ -6747,7 +6759,7 @@ then you need to update the crop frame by calling this method.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:39 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:07 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.SpriteBatch.html b/docs/Phaser.SpriteBatch.html index 0d0ad16c9..81e007d83 100644 --- a/docs/Phaser.SpriteBatch.html +++ b/docs/Phaser.SpriteBatch.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -561,8 +569,7 @@
    -

    Phaser SpriteBatch constructor. -The SpriteBatch class is a really fast version of the DisplayObjectContainer built purely for speed, so use when you need a lot of sprites or particles. +

    The SpriteBatch class is a really fast version of the DisplayObjectContainer built purely for speed, so use when you need a lot of sprites or particles. It's worth mentioning that by default sprite batches are used through-out the renderer, so you only really need to use a SpriteBatch if you have over 1000 sprites that all share the same texture (or texture atlas). It's also useful if running in Canvas mode and you have a lot of un-rotated or un-scaled Sprites as it skips all of the Canvas setTransform calls, which helps performance, especially on mobile devices.

    @@ -782,7 +789,7 @@ Sprites as it skips all of the Canvas setTransform calls, which helps performanc
    Source:
    @@ -924,7 +931,7 @@ Sprites as it skips all of the Canvas setTransform calls, which helps performanc
    Source:
    @@ -1031,7 +1038,7 @@ Sprites as it skips all of the Canvas setTransform calls, which helps performanc
    Source:
    @@ -1143,7 +1150,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1250,7 +1257,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1362,7 +1369,7 @@ When a new object is created it is passed the following parameters to its constr
    Source:
    @@ -1474,7 +1481,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1584,7 +1591,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1691,7 +1698,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1801,7 +1808,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -1914,7 +1921,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2021,7 +2028,117 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    + + + + + + + +
    + + + +
    + + + +
    +

    ignoreDestroy

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    ignoreDestroy + + +boolean + + + +

    A Group with ignoreDestroy set to true ignores all calls to its destroy method.

    +
    + + + + + + + + +
    Inherited From:
    +
    + + + + + + + + + + + +
    Default Value:
    +
    • false
    + + + +
    Source:
    +
    @@ -2128,7 +2245,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2235,7 +2352,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2342,7 +2459,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2449,7 +2566,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2561,7 +2678,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2668,7 +2785,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2775,7 +2892,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2877,7 +2994,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -2984,7 +3101,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3096,7 +3213,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3208,7 +3325,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3315,7 +3432,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -3491,7 +3608,7 @@ that then see the addAt method.

    Source:
    @@ -3716,7 +3833,7 @@ Group.addAll('x', 10) will add 10 to the child.x value.

    Source:
    @@ -3930,7 +4047,7 @@ The child is added to the Group at the location specified by the index value, th
    Source:
    @@ -4133,7 +4250,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4302,7 +4419,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4425,7 +4542,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -4664,7 +4781,7 @@ After the method parameter and context you can add as many extra parameters as y
    Source:
    @@ -4862,7 +4979,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -5031,7 +5148,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -5323,7 +5440,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5571,7 +5688,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5668,7 +5785,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -5765,7 +5882,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -6077,7 +6194,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -6359,7 +6476,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -6506,7 +6623,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -6652,7 +6769,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -6834,7 +6951,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -7027,7 +7144,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -7050,6 +7167,213 @@ Group.divideAll('x', 2) will half the child.x value.

    +
    + + + +
    +

    filter(predicate, checkExists) → {Phaser.ArrayList}

    + + +
    +
    + + +
    +

    Allows you to obtain a Phaser.ArrayList of children that return true for the given predicate +For example: + var healthyList = Group.filter(function(child, index, children) { + return child.health > 10 ? true : false; + }, true); + healthyList.callAll('attack'); +Note: Currently this will skip any children which are Groups themselves.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    predicate + + +function + + + + + + + + + + + +

    The function that each child will be evaluated against. Each child of the Group will be passed to it as its first parameter, the index as the second, and the entire child array as the third

    checkExists + + +boolean + + + + + + <optional>
    + + + + + +
    + + false + +

    If set only children with exists=true will be passed to the callback, otherwise all children will be passed.

    + + + + +
    + + + + + + + +
    Inherited From:
    +
    + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    Returns an array list containing all the children that the predicate returned true for

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.ArrayList + + +
    +
    + + + + +
    @@ -7243,7 +7567,7 @@ Note: Currently this will skip any children which are Groups themselves.

    Source:
    @@ -7391,7 +7715,7 @@ For example: Group.forEachAlive(causeDamage, this, 500)

    Source:
    @@ -7539,7 +7863,7 @@ For example: Group.forEachDead(bringToLife, this)

    Source:
    @@ -7687,7 +8011,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -7810,7 +8134,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -7907,7 +8231,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -8005,7 +8329,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8103,7 +8427,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8249,7 +8573,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8395,7 +8719,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8564,7 +8888,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8661,7 +8985,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -8830,7 +9154,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9140,7 +9464,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -9286,7 +9610,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -9432,7 +9756,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -9648,7 +9972,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -9722,7 +10046,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -9819,7 +10143,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -9893,7 +10217,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -9967,7 +10291,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10208,7 +10532,7 @@ reset the Group cursor and optionally destroy the child.

    Source:
    @@ -10414,7 +10738,7 @@ The Group container remains on the display list.

    Source:
    @@ -10668,7 +10992,7 @@ The Group container remains on the display list.

    Source:
    @@ -10814,7 +11138,7 @@ The Group container remains on the display list.

    Source:
    @@ -10980,7 +11304,7 @@ The Group container remains on the display list.

    Source:
    @@ -11077,7 +11401,7 @@ The Group container remains on the display list.

    Source:
    @@ -11200,7 +11524,7 @@ The Group container remains on the display list.

    Source:
    @@ -11589,7 +11913,7 @@ The operation parameter controls how the new value is assigned to the property,
    Source:
    @@ -11945,7 +12269,7 @@ If you need that ability please see Group.setAllChildren.

    Source:
    @@ -12278,7 +12602,7 @@ Unlike with Group.setAll the property is NOT set on child Groups itself.

    Source:
    @@ -12570,7 +12894,7 @@ Operation 0 means set the existing value to the given value, or if force is Source:
    @@ -12776,7 +13100,7 @@ For example to depth sort Sprites for Zelda-style game you might call grou
    Source:
    @@ -12969,7 +13293,7 @@ Group.subAll('x', 10) will minus 10 from the child.x value.

    Source:
    @@ -13116,7 +13440,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13190,7 +13514,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13264,7 +13588,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13433,7 +13757,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -13484,7 +13808,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:39 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:07 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Stage.html b/docs/Phaser.Stage.html index 1ad100dc1..159350006 100644 --- a/docs/Phaser.Stage.html +++ b/docs/Phaser.Stage.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -562,7 +570,7 @@

    The Stage controls root level display objects upon which everything is displayed. - It also handles browser visibility handling and the pausing due to loss of focus.

    +It also handles browser visibility handling and the pausing due to loss of focus.

    @@ -2077,7 +2085,7 @@ Most objects have preUpdate methods and it's where initial movement and position Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:40 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:07 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.State.html b/docs/Phaser.State.html index f2876ad47..dfbc0e75e 100644 --- a/docs/Phaser.State.html +++ b/docs/Phaser.State.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -3100,7 +3108,7 @@ If is called BEFORE Stage, Tweens, Sounds, Input, Physics, Particles and Plugins Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:40 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:08 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.StateManager.html b/docs/Phaser.StateManager.html index 685d6f946..d0a3eb368 100644 --- a/docs/Phaser.StateManager.html +++ b/docs/Phaser.StateManager.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -2571,7 +2579,7 @@ If a function is given a new state object will be created by calling it.

    Source:
    @@ -2689,7 +2697,7 @@ If a function is given a new state object will be created by calling it.

    Source:
    @@ -2782,7 +2790,7 @@ resets the camera, resets input, clears physics, removes timers and if set clear
    Source:
    @@ -2852,7 +2860,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -2921,7 +2929,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3050,7 +3058,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3115,7 +3123,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3180,7 +3188,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3245,7 +3253,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3310,7 +3318,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3379,7 +3387,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3497,7 +3505,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3562,7 +3570,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3627,7 +3635,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3841,7 +3849,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -3906,7 +3914,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -4155,7 +4163,125 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    + + + + + + + +
    + + + + + + + + + + + + + + + + + +
    + + + +
    +
    + + +
    +

    Nulls all State level Phaser properties, including a reference to Game.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    key + + +string + + + +

    State key.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -4220,7 +4346,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Source:
    @@ -4271,7 +4397,7 @@ You don't recover from this without rebuilding the Phaser instance again.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:40 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:08 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Text.html b/docs/Phaser.Text.html index 2268371fe..1cbb520eb 100644 --- a/docs/Phaser.Text.html +++ b/docs/Phaser.Text.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -871,7 +879,7 @@ Here is a compatibility table showing the available default fonts across differe
    Source:
    @@ -979,7 +987,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1081,7 +1089,109 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    + + + + + + + +
    + + + +
    + + + +
    +

    colors

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    colors + + +array + + + +

    An array of the color values as specified by Text.addColor.

    +
    + + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    @@ -1183,7 +1293,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1285,7 +1395,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1492,7 +1602,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1600,7 +1710,7 @@ So if this Text was in a Group that has x: 200, then this will be added to the c
    Source:
    @@ -1702,7 +1812,7 @@ So if this Text was in a Group that has x: 200, then this will be added to the c
    Source:
    @@ -1804,7 +1914,7 @@ So if this Text was in a Group that has x: 200, then this will be added to the c
    Source:
    @@ -1906,7 +2016,7 @@ So if this Text was in a Group that has x: 200, then this will be added to the c
    Source:
    @@ -2113,7 +2223,7 @@ So if this Text was in a Group that has x: 200, then this will be added to the c
    Source:
    @@ -2220,7 +2330,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2322,7 +2432,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2526,7 +2636,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2628,7 +2738,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2730,7 +2840,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2832,7 +2942,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2934,7 +3044,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3036,7 +3146,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3142,7 +3252,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3346,7 +3456,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3448,7 +3558,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3675,6 +3785,220 @@ activated for this object and it will then start to process click/touch events a
    +
    +

    addColor(color, position)

    + + +
    +
    + + +
    +

    This method allows you to set specific colors within the Text. +It works by taking a color value, which is a typical HTML string such as #ff0000 or rgb(255,0,0) and a position. +The position value is the index of the character in the Text string to start applying this color to. +Once set the color remains in use until either another color or the end of the string is encountered. +For example if the Text was Photon Storm and you did Text.addColor('#ffff00', 6) it would color in the word Storm in yellow.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    color + + +string + + + +

    A canvas fillstyle that will be used on the text eg red, #00FF00, rgba().

    position + + +number + + + +

    The index of the character in the string to start applying this color value from.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + + + +
    + + + +
    +

    clearColors()

    + + +
    +
    + + +
    +

    Clears any previously set color stops.

    +
    + + + + + + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + + + +
    + + +

    destroy(destroyChildren)

    @@ -3782,7 +4106,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3851,7 +4175,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3920,7 +4244,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4171,7 +4495,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4269,7 +4593,7 @@ activated for this object and it will then start to process click/touch events a -

    The style parameters

    +

    The style properties to be set on the Text.

    Properties
    @@ -4305,7 +4629,7 @@ activated for this object and it will then start to process click/touch events a -String +string @@ -4331,7 +4655,7 @@ activated for this object and it will then start to process click/touch events a -

    The style and size of the font

    +

    The style and size of the font.

    @@ -4344,7 +4668,7 @@ activated for this object and it will then start to process click/touch events a -Object +string @@ -4370,7 +4694,7 @@ activated for this object and it will then start to process click/touch events a -

    A canvas fillstyle that will be used on the text eg 'red', '#00FF00'

    +

    A canvas fillstyle that will be used on the text eg 'red', '#00FF00'.

    @@ -4383,7 +4707,7 @@ activated for this object and it will then start to process click/touch events a -String +string @@ -4409,7 +4733,7 @@ activated for this object and it will then start to process click/touch events a -

    Alignment for multiline text ('left', 'center' or 'right'), does not affect single line text

    +

    Alignment for multiline text ('left', 'center' or 'right'), does not affect single line text.

    @@ -4422,7 +4746,7 @@ activated for this object and it will then start to process click/touch events a -String +string @@ -4448,7 +4772,7 @@ activated for this object and it will then start to process click/touch events a -

    A canvas fillstyle that will be used on the text stroke eg 'blue', '#FCFF00'

    +

    A canvas stroke style that will be used on the text stroke eg 'blue', '#FCFF00'.

    @@ -4461,7 +4785,7 @@ activated for this object and it will then start to process click/touch events a -Number +number @@ -4487,7 +4811,7 @@ activated for this object and it will then start to process click/touch events a -

    A number that represents the thickness of the stroke. Default is 0 (no stroke)

    +

    A number that represents the thickness of the stroke. Default is 0 (no stroke).

    @@ -4500,7 +4824,7 @@ activated for this object and it will then start to process click/touch events a -Boolean +boolean @@ -4526,7 +4850,7 @@ activated for this object and it will then start to process click/touch events a -

    Indicates if word wrap should be used

    +

    Indicates if word wrap should be used.

    @@ -4539,7 +4863,7 @@ activated for this object and it will then start to process click/touch events a -Number +number @@ -4565,7 +4889,7 @@ activated for this object and it will then start to process click/touch events a -

    The width at which text will wrap

    +

    The width in pixels at which text will wrap.

    @@ -4604,7 +4928,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4673,7 +4997,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -4724,7 +5048,7 @@ activated for this object and it will then start to process click/touch events a Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:40 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:08 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Tile.html b/docs/Phaser.Tile.html index 8538a8dd2..fde56c5fc 100644 --- a/docs/Phaser.Tile.html +++ b/docs/Phaser.Tile.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Tile -

    A Tile is a representation of a single tile within the Tilemap.

    +

    Phaser.Tile

    @@ -561,7 +569,7 @@
    -

    Create a new Tile object.

    +

    A Tile is a representation of a single tile within the Tilemap.

    @@ -758,7 +766,7 @@
    Source:
    @@ -886,7 +894,7 @@
    Source:
    @@ -988,7 +996,7 @@
    Source:
    @@ -1090,7 +1098,7 @@
    Source:
    @@ -1192,7 +1200,7 @@
    Source:
    @@ -1294,7 +1302,7 @@
    Source:
    @@ -1399,7 +1407,7 @@
    Source:
    @@ -1504,7 +1512,7 @@
    Source:
    @@ -1609,7 +1617,7 @@
    Source:
    @@ -1711,7 +1719,7 @@
    Source:
    @@ -1816,7 +1824,7 @@
    Source:
    @@ -1921,7 +1929,7 @@
    Source:
    @@ -2023,7 +2031,7 @@
    Source:
    @@ -2125,7 +2133,7 @@
    Source:
    @@ -2227,7 +2235,7 @@
    Source:
    @@ -2329,7 +2337,7 @@
    Source:
    @@ -2431,7 +2439,7 @@
    Source:
    @@ -2533,7 +2541,7 @@
    Source:
    @@ -2635,7 +2643,7 @@
    Source:
    @@ -2737,7 +2745,7 @@
    Source:
    @@ -2839,7 +2847,7 @@
    Source:
    @@ -2941,7 +2949,7 @@
    Source:
    @@ -3043,7 +3051,7 @@
    Source:
    @@ -3145,7 +3153,7 @@
    Source:
    @@ -3247,7 +3255,7 @@
    Source:
    @@ -3349,7 +3357,7 @@
    Source:
    @@ -3451,7 +3459,7 @@
    Source:
    @@ -3553,7 +3561,7 @@
    Source:
    @@ -3655,7 +3663,7 @@
    Source:
    @@ -3757,7 +3765,7 @@
    Source:
    @@ -3894,7 +3902,7 @@
    Source:
    @@ -4035,7 +4043,7 @@
    Source:
    @@ -4104,7 +4112,7 @@
    Source:
    @@ -4291,7 +4299,7 @@
    Source:
    @@ -4432,7 +4440,7 @@
    Source:
    @@ -4524,7 +4532,7 @@
    Source:
    @@ -4711,7 +4719,7 @@
    Source:
    @@ -4853,7 +4861,7 @@ The callback must true true for collision processing to take place.

    Source:
    @@ -4904,7 +4912,7 @@ The callback must true true for collision processing to take place.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:40 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:08 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.TileSprite.html b/docs/Phaser.TileSprite.html index e60271181..9a1904e45 100644 --- a/docs/Phaser.TileSprite.html +++ b/docs/Phaser.TileSprite.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -794,7 +802,7 @@ Please note that TileSprites, as with normal Sprites, have no input handler or p
    Source:
    @@ -823,6 +831,12 @@ Please note that TileSprites, as with normal Sprites, have no input handler or p +

    Extends

    + +
      +
    • Pixi.TilingSprite
    • +
    + @@ -925,7 +939,7 @@ Please note that TileSprites, as with normal Sprites, have no input handler or p
    Source:
    @@ -1033,7 +1047,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1135,7 +1149,7 @@ If you wish to work in radians instead of degrees use the property Sprite.rotati
    Source:
    @@ -1246,7 +1260,7 @@ Be advised this is quite an expensive operation, as it has to calculate the boun
    Source:
    @@ -1368,7 +1382,7 @@ If you need a different result then adjust or re-create the Body shape offsets m
    Source:
    @@ -1470,7 +1484,7 @@ If you need a different result then adjust or re-create the Body shape offsets m
    Source:
    @@ -1581,7 +1595,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1683,7 +1697,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1785,7 +1799,7 @@ bounds every frame to support it, and not all games need it. Enable it by settin
    Source:
    @@ -1893,7 +1907,7 @@ Setting TileSprite.exists to true will re-add the Body to the physics world (if
    Source:
    @@ -2001,7 +2015,7 @@ So if this TileSprite was in a Group that has x: 200, then this will be added to
    Source:
    @@ -2103,7 +2117,7 @@ So if this TileSprite was in a Group that has x: 200, then this will be added to
    Source:
    @@ -2205,7 +2219,7 @@ So if this TileSprite was in a Group that has x: 200, then this will be added to
    Source:
    @@ -2307,7 +2321,7 @@ So if this TileSprite was in a Group that has x: 200, then this will be added to
    Source:
    @@ -2412,7 +2426,7 @@ So if this TileSprite was in a Group that has x: 200, then this will be added to
    Source:
    @@ -2519,7 +2533,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2630,7 +2644,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2732,7 +2746,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2834,7 +2848,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -2936,7 +2950,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3042,7 +3056,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3148,7 +3162,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3250,7 +3264,7 @@ activated for this object and it will then start to process click/touch events a
    Source:
    @@ -3390,7 +3404,7 @@ A negative y value will scroll up. A positive y value will scroll down.

    Source:
    @@ -3529,7 +3543,7 @@ and nulls its reference to game, freeing it up for garbage collection.

    Source:
    @@ -3683,7 +3697,7 @@ This causes a WebGL texture update, so use sparingly or in low-intensity portion
    Source:
    @@ -3935,7 +3949,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -4027,7 +4041,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -4096,7 +4110,7 @@ If the requested animation is already playing this request will be ignored. If y
    Source:
    @@ -4239,7 +4253,7 @@ If the TileSprite has a physics body that too is reset.

    Source:
    @@ -4369,7 +4383,7 @@ This is primarily an internal method used by TileSprite.loadTexture, although yo
    Source:
    @@ -4438,7 +4452,7 @@ This is primarily an internal method used by TileSprite.loadTexture, although yo
    Source:
    @@ -4507,7 +4521,7 @@ This is primarily an internal method used by TileSprite.loadTexture, although yo
    Source:
    @@ -4558,7 +4572,7 @@ This is primarily an internal method used by TileSprite.loadTexture, although yo Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:41 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:09 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Tilemap.html b/docs/Phaser.Tilemap.html index d297bf8df..f556c2155 100644 --- a/docs/Phaser.Tilemap.html +++ b/docs/Phaser.Tilemap.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -13510,7 +13518,7 @@ If you want to set a callback for a tile at a specific location on the map then Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:41 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:09 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.TilemapLayer.html b/docs/Phaser.TilemapLayer.html index 9e01ae24d..f769d7a06 100644 --- a/docs/Phaser.TilemapLayer.html +++ b/docs/Phaser.TilemapLayer.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -5242,7 +5250,7 @@ half as quickly as the 'normal' camera-locked layers do)

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:41 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:09 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.TilemapParser.html b/docs/Phaser.TilemapParser.html index 93d1e1a78..a37b243e0 100644 --- a/docs/Phaser.TilemapParser.html +++ b/docs/Phaser.TilemapParser.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1477,7 +1485,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:41 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:09 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Tileset.html b/docs/Phaser.Tileset.html index 206287734..16a18cf5d 100644 --- a/docs/Phaser.Tileset.html +++ b/docs/Phaser.Tileset.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -2551,7 +2559,7 @@ You should not normally instantiate this class directly.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:41 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:09 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Time.html b/docs/Phaser.Time.html index 6420becdf..f383b8b0f 100644 --- a/docs/Phaser.Time.html +++ b/docs/Phaser.Time.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Time -

    This is the core internal game clock. It manages the elapsed time and calculation of elapsed values, used for game object motion and tweens.

    +

    Phaser.Time

    @@ -561,7 +569,8 @@
    -

    Time constructor.

    +

    This is the core internal game clock. +It manages the elapsed time and calculation of elapsed values, used for game object motion and tweens.

    @@ -3661,7 +3670,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:42 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:10 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Timer.html b/docs/Phaser.Timer.html index ef228fa48..823fc2583 100644 --- a/docs/Phaser.Timer.html +++ b/docs/Phaser.Timer.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Timer -

    A Timer is a way to create small re-usable or disposable objects that do nothing but wait for a specific moment in time, and then dispatch an event.

    +

    Phaser.Timer

    @@ -700,7 +708,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -786,7 +794,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -846,7 +854,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -906,7 +914,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -966,7 +974,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -1068,7 +1076,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -1170,7 +1178,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -1272,7 +1280,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -1374,7 +1382,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -1479,7 +1487,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -1581,7 +1589,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -1683,7 +1691,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -1785,7 +1793,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -1887,7 +1895,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -1989,7 +1997,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -2091,7 +2099,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -2196,7 +2204,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -2301,7 +2309,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -2403,7 +2411,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -2505,7 +2513,7 @@ So if you want to fire an event every quarter of a second you'd need to set the
    Source:
    @@ -2726,7 +2734,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -2818,7 +2826,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -2887,7 +2895,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -2957,7 +2965,7 @@ The onComplete callbacks won't be called.

    Source:
    @@ -3183,7 +3191,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -3275,7 +3283,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -3344,7 +3352,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -3462,7 +3470,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -3532,7 +3540,7 @@ The onComplete callbacks won't be called.

    Source:
    @@ -3789,7 +3797,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -3881,7 +3889,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -3950,7 +3958,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -4088,7 +4096,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -4226,7 +4234,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -4344,7 +4352,7 @@ If the Timer is already running the delay will be calculated based on the timers
    Source:
    @@ -4418,7 +4426,7 @@ If the Timer is already running the delay will be calculated based on the timers Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:42 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:10 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.TimerEvent.html b/docs/Phaser.TimerEvent.html index 70b72a7be..e9963fdfe 100644 --- a/docs/Phaser.TimerEvent.html +++ b/docs/Phaser.TimerEvent.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ TimerEvent -

    A TimerEvent is a single event that is processed by a Phaser.Timer. It consists of a delay, which is a value in milliseconds after which the event will fire.

    +

    Phaser.TimerEvent

    @@ -561,7 +569,8 @@
    -

    A TimerEvent is a single event that is processed by a Phaser.Timer. It consists of a delay, which is a value in milliseconds after which the event will fire. +

    A TimerEvent is a single event that is processed by a Phaser.Timer. +It consists of a delay, which is a value in milliseconds after which the event will fire. It can call a specific callback, passing in optional parameters.

    @@ -1792,7 +1801,7 @@ It can call a specific callback, passing in optional parameters.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:42 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:10 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Touch.html b/docs/Phaser.Touch.html index 0286e937c..1d8b50022 100644 --- a/docs/Phaser.Touch.html +++ b/docs/Phaser.Touch.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,7 +550,7 @@ Touch -

    The Touch class handles touch interactions with the game and the resulting Pointer objects.

    +

    Phaser.Touch

    @@ -643,7 +651,7 @@
    Source:
    @@ -771,7 +779,7 @@
    Source:
    @@ -873,7 +881,7 @@
    Source:
    @@ -978,7 +986,7 @@
    Source:
    @@ -1080,7 +1088,7 @@
    Source:
    @@ -1185,7 +1193,7 @@
    Source:
    @@ -1287,7 +1295,7 @@
    Source:
    @@ -1389,7 +1397,7 @@
    Source:
    @@ -1491,7 +1499,7 @@
    Source:
    @@ -1593,7 +1601,7 @@
    Source:
    @@ -1695,7 +1703,7 @@
    Source:
    @@ -1797,7 +1805,7 @@
    Source:
    @@ -1862,7 +1870,7 @@
    Source:
    @@ -1981,7 +1989,7 @@ Occurs for example on iOS when you put down 4 fingers and the app selector UI ap
    Source:
    @@ -2099,7 +2107,7 @@ Occurs for example on iOS when you put down 4 fingers and the app selector UI ap
    Source:
    @@ -2218,7 +2226,7 @@ Doesn't appear to be supported by most browsers on a canvas element yet.

    Source:
    @@ -2337,7 +2345,7 @@ Doesn't appear to be supported by most browsers on a canvas element yet.

    Source:
    @@ -2455,7 +2463,7 @@ Doesn't appear to be supported by most browsers on a canvas element yet.

    Source:
    @@ -2573,7 +2581,7 @@ Doesn't appear to be supported by most browsers on a canvas element yet.

    Source:
    @@ -2642,7 +2650,7 @@ Doesn't appear to be supported by most browsers on a canvas element yet.

    Source:
    @@ -2711,7 +2719,7 @@ Doesn't appear to be supported by most browsers on a canvas element yet.

    Source:
    @@ -2762,7 +2770,7 @@ Doesn't appear to be supported by most browsers on a canvas element yet.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:42 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:10 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Tween.html b/docs/Phaser.Tween.html index fcc7c8c38..c667f0b0a 100644 --- a/docs/Phaser.Tween.html +++ b/docs/Phaser.Tween.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -3890,7 +3898,7 @@ Used in combination with repeat you can create endless loops.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:42 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:10 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.TweenManager.html b/docs/Phaser.TweenManager.html index 923ac7cf0..579ab3765 100644 --- a/docs/Phaser.TweenManager.html +++ b/docs/Phaser.TweenManager.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -542,12 +550,7 @@ TweenManager -

    Phaser.Game has a single instance of the TweenManager through which all Tween objects are created and updated. -Tweens are hooked into the game clock and pause system, adjusting based on the game state.

    -

    TweenManager is based heavily on tween.js by http://soledadpenades.com. -The difference being that tweens belong to a games instance of TweenManager, rather than to a global TWEEN object. -It also has callbacks swapped for Signals and a few issues patched with regard to properties and completion errors. -Please see https://github.com/sole/tween.js for a full list of contributors.

    +

    Phaser.TweenManager

    @@ -566,7 +569,12 @@ Please see https://github.com/sole/tw
    -

    Phaser - TweenManager

    +

    Phaser.Game has a single instance of the TweenManager through which all Tween objects are created and updated. +Tweens are hooked into the game clock and pause system, adjusting based on the game state.

    +

    TweenManager is based heavily on tween.js by http://soledadpenades.com. +The difference being that tweens belong to a games instance of TweenManager, rather than to a global TWEEN object. +It also has callbacks swapped for Signals and a few issues patched with regard to properties and completion errors. +Please see https://github.com/sole/tween.js for a full list of contributors.

    @@ -648,7 +656,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -776,7 +784,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -890,7 +898,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -1031,7 +1039,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -1123,7 +1131,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -1264,7 +1272,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -1356,7 +1364,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -1474,7 +1482,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -1543,7 +1551,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -1612,7 +1620,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -1681,7 +1689,7 @@ Please see https://github.com/sole/tw
    Source:
    @@ -1755,7 +1763,7 @@ Please see https://github.com/sole/tw Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:43 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:11 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Utils.Debug.html b/docs/Phaser.Utils.Debug.html index 5f12d2b8c..d3dba0d24 100644 --- a/docs/Phaser.Utils.Debug.html +++ b/docs/Phaser.Utils.Debug.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -2667,7 +2675,7 @@ To display a P2 body you should enable debug mode on the body when creating it.<
    Source:
    @@ -2759,6 +2767,251 @@ To display a P2 body you should enable debug mode on the body when creating it.< +
    + + + +
    +

    box2dBody(sprite, color)

    + + +
    +
    + + +
    +

    Renders 'debug draw' data for the given Box2D body. +This uses the standard debug drawing feature of Box2D, so colors will be decided by the Box2D engine.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    sprite + + +Phaser.Sprite + + + + + + + + + + + +

    The sprite whos body will be rendered.

    color + + +string + + + + + + <optional>
    + + + + + +
    + + 'rgb(0,255,0)' + +

    color of the debug info to be rendered. (format is css color string).

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + + + +
    + + + +
    +

    box2dWorld()

    + + +
    +
    + + +
    +

    Renders 'debug draw' data for the Box2D world if it exists. +This uses the standard debug drawing feature of Box2D, so colors will be decided by +the Box2D engine.

    +
    + + + + + + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + + +
    @@ -7302,7 +7555,7 @@ To display a P2 body you should enable debug mode on the body when creating it.< Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:43 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:11 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.Utils.html b/docs/Phaser.Utils.html index 274367506..057161f94 100644 --- a/docs/Phaser.Utils.html +++ b/docs/Phaser.Utils.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -2356,7 +2364,7 @@ Based on the routine from http: Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:43 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:11 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.World.html b/docs/Phaser.World.html index aea079ea2..d819045bf 100644 --- a/docs/Phaser.World.html +++ b/docs/Phaser.World.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1094,7 +1102,7 @@ the world at world-based coordinates. By default a world is created the same siz
    Source:
    @@ -1201,7 +1209,7 @@ the world at world-based coordinates. By default a world is created the same siz
    Source:
    @@ -1313,7 +1321,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -1631,7 +1639,7 @@ So if you want to make a game in which the world itself will rotate you should a
    Source:
    @@ -1947,7 +1955,7 @@ When a new object is created it is passed the following parameters to its constr
    Source:
    @@ -2059,7 +2067,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -2169,7 +2177,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -2276,7 +2284,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -2386,7 +2394,7 @@ The cursor is set to the first child added to the Group and doesn't change unles
    Source:
    @@ -2499,7 +2507,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2606,7 +2614,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2717,6 +2725,116 @@ So if this Group was in a Group that has x: 200, then this will be added to the + + + + + + + + +
    +

    ignoreDestroy

    + + +
    +
    + + + + + +
    + + +
    Properties:
    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeDescription
    ignoreDestroy + + +boolean + + + +

    A Group with ignoreDestroy set to true ignores all calls to its destroy method.

    +
    + + + + + + + + +
    Inherited From:
    +
    + + + + + + + + + + + +
    Default Value:
    +
    • false
    + + + +
    Source:
    +
    + + + + + + +
    @@ -2815,7 +2933,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -2922,7 +3040,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3029,7 +3147,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3136,7 +3254,7 @@ So if this Group was in a Group that has x: 200, then this will be added to the
    Source:
    @@ -3452,7 +3570,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3559,7 +3677,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3666,7 +3784,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3773,7 +3891,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -3880,7 +3998,7 @@ This will have no impact on the rotation value of its children, but it will upda
    Source:
    @@ -4094,7 +4212,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -4206,7 +4324,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -4313,7 +4431,7 @@ This will have no impact on the x/y coordinates of its children, but it will upd
    Source:
    @@ -4489,7 +4607,7 @@ that then see the addAt method.

    Source:
    @@ -4714,7 +4832,7 @@ Group.addAll('x', 10) will add 10 to the child.x value.

    Source:
    @@ -4928,7 +5046,7 @@ The child is added to the Group at the location specified by the index value, th
    Source:
    @@ -5131,7 +5249,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -5300,7 +5418,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -5492,7 +5610,7 @@ TODO: Add ability to pass the children as parameters rather than having to be an
    Source:
    @@ -5731,7 +5849,7 @@ After the method parameter and context you can add as many extra parameters as y
    Source:
    @@ -5929,7 +6047,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -6098,7 +6216,7 @@ After the existsValue parameter you can add as many parameters as you like, whic
    Source:
    @@ -6390,7 +6508,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -6638,7 +6756,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -6735,7 +6853,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -6832,7 +6950,7 @@ This call doesn't descend down children, so if you have a Group inside of this G
    Source:
    @@ -7144,7 +7262,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -7426,7 +7544,7 @@ You can change Group.classType to any object and this call will create an object
    Source:
    @@ -7573,7 +7691,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -7719,7 +7837,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -7901,7 +8019,7 @@ It will be sent two parameters: the two children involved in the comparison (a a
    Source:
    @@ -8094,7 +8212,7 @@ Group.divideAll('x', 2) will half the child.x value.

    Source:
    @@ -8117,6 +8235,213 @@ Group.divideAll('x', 2) will half the child.x value.

    + + + + +
    +

    filter(predicate, checkExists) → {Phaser.ArrayList}

    + + +
    +
    + + +
    +

    Allows you to obtain a Phaser.ArrayList of children that return true for the given predicate +For example: + var healthyList = Group.filter(function(child, index, children) { + return child.health > 10 ? true : false; + }, true); + healthyList.callAll('attack'); +Note: Currently this will skip any children which are Groups themselves.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDefaultDescription
    predicate + + +function + + + + + + + + + + + +

    The function that each child will be evaluated against. Each child of the Group will be passed to it as its first parameter, the index as the second, and the entire child array as the third

    checkExists + + +boolean + + + + + + <optional>
    + + + + + +
    + + false + +

    If set only children with exists=true will be passed to the callback, otherwise all children will be passed.

    + + + + +
    + + + + + + + +
    Inherited From:
    +
    + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    Returns an array list containing all the children that the predicate returned true for

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.ArrayList + + +
    +
    + + + + +
    @@ -8310,7 +8635,7 @@ Note: Currently this will skip any children which are Groups themselves.

    Source:
    @@ -8458,7 +8783,7 @@ For example: Group.forEachAlive(causeDamage, this, 500)

    Source:
    @@ -8606,7 +8931,7 @@ For example: Group.forEachDead(bringToLife, this)

    Source:
    @@ -8754,7 +9079,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -8877,7 +9202,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -8974,7 +9299,7 @@ For example: Group.forEachExists(causeDamage, this, 500)

    Source:
    @@ -9072,7 +9397,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9170,7 +9495,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9316,7 +9641,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9462,7 +9787,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9631,7 +9956,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9728,7 +10053,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -9897,7 +10222,7 @@ This is handy for checking if everything has been wiped out, or choosing a squad
    Source:
    @@ -10207,7 +10532,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -10353,7 +10678,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -10499,7 +10824,7 @@ You can add as many callback parameters as you like, which will all be passed to
    Source:
    @@ -10715,7 +11040,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10789,7 +11114,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10886,7 +11211,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -10960,7 +11285,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -11034,7 +11359,7 @@ Group.multiplyAll('x', 2) will x2 the child.x value.

    Source:
    @@ -11275,7 +11600,7 @@ reset the Group cursor and optionally destroy the child.

    Source:
    @@ -11481,7 +11806,7 @@ The Group container remains on the display list.

    Source:
    @@ -11735,7 +12060,7 @@ The Group container remains on the display list.

    Source:
    @@ -11881,7 +12206,7 @@ The Group container remains on the display list.

    Source:
    @@ -12047,7 +12372,7 @@ The Group container remains on the display list.

    Source:
    @@ -12144,7 +12469,7 @@ The Group container remains on the display list.

    Source:
    @@ -12267,7 +12592,7 @@ The Group container remains on the display list.

    Source:
    @@ -12656,7 +12981,7 @@ The operation parameter controls how the new value is assigned to the property,
    Source:
    @@ -13012,7 +13337,7 @@ If you need that ability please see Group.setAllChildren.

    Source:
    @@ -13345,7 +13670,7 @@ Unlike with Group.setAll the property is NOT set on child Groups itself.

    Source:
    @@ -13825,7 +14150,7 @@ Operation 0 means set the existing value to the given value, or if force is Source:
    @@ -14100,7 +14425,7 @@ For example to depth sort Sprites for Zelda-style game you might call grou
    Source:
    @@ -14293,7 +14618,7 @@ Group.subAll('x', 10) will minus 10 from the child.x value.

    Source:
    @@ -14440,7 +14765,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -14514,7 +14839,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -14588,7 +14913,7 @@ You cannot swap a child with itself, or swap un-parented children.

    Source:
    @@ -15058,7 +15383,7 @@ If sprite has a P2 body then the body (sprite.body) should be passed as first pa
    Source:
    @@ -15109,7 +15434,7 @@ If sprite has a P2 body then the body (sprite.body) should be passed as first pa Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:43 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:10:11 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.html b/docs/Phaser.html index c066bdf72..cc92d7702 100644 --- a/docs/Phaser.html +++ b/docs/Phaser.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -632,6 +640,14 @@ +
    + AudioSprite +
    +
    + +
    + +
    BitmapData
    @@ -976,14 +992,6 @@ -
    - Point -
    -
    - -
    - -
    Pointer
    @@ -1295,7 +1303,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:46 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Phaser.js.html b/docs/Phaser.js.html index be0b68e53..33ede698c 100644 --- a/docs/Phaser.js.html +++ b/docs/Phaser.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -548,7 +556,7 @@ */ var Phaser = Phaser || { - VERSION: '2.1.0', + VERSION: '2.1.2', GAMES: [], AUTO: 0, @@ -642,7 +650,7 @@ PIXI.dontSayHello = true; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Physics.js.html b/docs/Physics.js.html index d2ddd4ddf..cdecb644b 100644 --- a/docs/Physics.js.html +++ b/docs/Physics.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -551,7 +559,6 @@ * faster (due to being much simpler) Arcade Physics system. * * @class Phaser.Physics -* * @constructor * @param {Phaser.Game} game - A reference to the currently running game. * @param {object} [physicsConfig=null] - A physics configuration object to pass to the Physics world on creation. @@ -627,7 +634,7 @@ Phaser.Physics.BOX2D = 3; * @const * @type {number} */ -Phaser.Physics.CHIPMUNK = 5; +Phaser.Physics.CHIPMUNK = 4; Phaser.Physics.prototype = { @@ -655,6 +662,11 @@ Phaser.Physics.prototype = { this.p2 = new Phaser.Physics.P2(this.game, this.config); } + if (this.config.hasOwnProperty('box2d') && this.config['box2d'] === true && Phaser.Physics.hasOwnProperty('BOX2D')) + { + this.box2d = new Phaser.Physics.BOX2D(this.game, this.config); + } + }, /** @@ -684,7 +696,7 @@ Phaser.Physics.prototype = { } else if (system === Phaser.Physics.BOX2D && this.box2d === null) { - throw new Error('The Box2D physics system has not been implemented yet.'); + this.box2d = new Phaser.Physics.Box2D(this.game, this.config); } else if (system === Phaser.Physics.CHIPMUNK && this.chipmunk === null) { @@ -701,7 +713,8 @@ Phaser.Physics.prototype = { * Phaser.Physics.Arcade - A light weight AABB based collision system with basic separation. * Phaser.Physics.P2JS - A full-body advanced physics system supporting multiple object shapes, polygon loading, contact materials, springs and constraints. * Phaser.Physics.NINJA - A port of Metanet Softwares N+ physics system. Advanced AABB and Circle vs. Tile collision. - * Phaser.Physics.BOX2D and Phaser.Physics.CHIPMUNK are still in development. + * Phaser.Physics.BOX2D - A port of https://code.google.com/p/box2d-html5 + * Phaser.Physics.CHIPMUNK is still in development. * * If you require more control over what type of body is created, for example to create a Ninja Physics Circle instead of the default AABB, then see the * individual physics systems `enable` methods instead of using this generic one. @@ -728,6 +741,10 @@ Phaser.Physics.prototype = { { this.ninja.enableAABB(object); } + else if (system === Phaser.Physics.BOX2D && this.box2d) + { + this.box2d.enable(object); + } }, @@ -746,6 +763,11 @@ Phaser.Physics.prototype = { this.p2.preUpdate(); } + if (this.box2d) + { + this.box2d.preUpdate(); + } + }, /** @@ -763,6 +785,11 @@ Phaser.Physics.prototype = { this.p2.update(); } + if (this.box2d) + { + this.box2d.update(); + } + }, /** @@ -788,6 +815,11 @@ Phaser.Physics.prototype = { this.p2.setBoundsToWorld(); } + if (this.box2d) + { + this.box2d.setBoundsToWorld(); + } + }, /** @@ -803,6 +835,11 @@ Phaser.Physics.prototype = { this.p2.clear(); } + if (this.box2d) + { + this.box2d.clear(); + } + }, /** @@ -817,9 +854,15 @@ Phaser.Physics.prototype = { this.p2.destroy(); } + if (this.box2d) + { + this.box2d.destroy(); + } + this.arcade = null; this.ninja = null; this.p2 = null; + this.box2d = null; } @@ -847,7 +890,7 @@ Phaser.Physics.prototype.constructor = Phaser.Physics; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Plugin.js.html b/docs/Plugin.js.html index 6b471fb90..c3cd34c52 100644 --- a/docs/Plugin.js.html +++ b/docs/Plugin.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * This is a base Plugin template to use for any Phaser plugin development. * * @class Phaser.Plugin -* @classdesc Phaser - Plugin * @constructor * @param {Phaser.Game} game - A reference to the currently running game. * @param {Any} parent - The object that owns this plugin, usually Phaser.PluginManager. @@ -680,7 +687,7 @@ Phaser.Plugin.prototype.constructor = Phaser.Plugin; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/PluginManager.js.html b/docs/PluginManager.js.html index 3c6dc860c..85ebc24fd 100644 --- a/docs/PluginManager.js.html +++ b/docs/PluginManager.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -548,7 +556,6 @@ * The Plugin Manager is responsible for the loading, running and unloading of Phaser Plugins. * * @class Phaser.PluginManager -* @classdesc Phaser - PluginManager * @constructor * @param {Phaser.Game} game - A reference to the currently running game. */ @@ -845,7 +852,7 @@ Phaser.PluginManager.prototype.constructor = Phaser.PluginManager; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Point.js.html b/docs/Point.js.html index 96cbec08a..baf3b2996 100644 --- a/docs/Point.js.html +++ b/docs/Point.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,18 +551,12 @@ */ /** -* @class Phaser.Point -* @classdesc -* The Point object represents a location in a two-dimensional coordinate system, -* where x represents the horizontal axis and y represents the vertical axis. +* A Point object represents a location in a two-dimensional coordinate system, where x represents the horizontal axis and y represents the vertical axis. * The following code creates a point at (0,0): * `var myPoint = new Phaser.Point();` * You can also use them as 2D Vectors and you'll find different vector related methods in this class. -*/ - -/** -* Creates a new Point object. If you pass no parameters a Point is created set to (0, 0). -* +* +* @class Phaser.Point * @constructor * @param {number} [x=0] - The horizontal position of this Point. * @param {number} [y=0] - The vertical position of this Point. @@ -1408,6 +1410,38 @@ Phaser.Point.centroid = function (points, out) { }; +/** +* Parses an object for x and/or y properties and returns a new Phaser.Point with matching values. +* If the object doesn't contain those properties a Point with x/y of zero will be returned. +* +* @method Phaser.Point.parse +* @static +* @param {Object} obj - The object to parse. +* @param {string} [xProp='x'] - The property used to set the Point.x value. +* @param {string} [yProp='y'] - The property used to set the Point.y value. +* @return {Phaser.Point} The new Point object. +*/ +Phaser.Point.parse = function(obj, xProp, yProp) { + + xProp = xProp || 'x'; + yProp = yProp || 'y'; + + var point = new Phaser.Point(); + + if (obj[xProp]) + { + point.x = parseInt(obj[xProp], 10); + } + + if (obj[yProp]) + { + point.y = parseInt(obj[yProp], 10); + } + + return point; + +}; + // Because PIXI uses its own Point, we'll replace it with ours to avoid duplicating code or confusion. PIXI.Point = Phaser.Point; @@ -1431,7 +1465,7 @@ PIXI.Point = Phaser.Point; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/PointProxy.js.html b/docs/PointProxy.js.html index 49b63ccb0..d4c75eddc 100644 --- a/docs/PointProxy.js.html +++ b/docs/PointProxy.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * A PointProxy is an internal class that allows for direct getter/setter style property access to Arrays and TypedArrays. * * @class Phaser.Physics.P2.PointProxy -* @classdesc PointProxy * @constructor * @param {Phaser.Physics.P2} world - A reference to the P2 World. * @param {any} destination - The object to bind to. @@ -660,7 +667,7 @@ Object.defineProperty(Phaser.Physics.P2.PointProxy.prototype, "my", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Pointer.js.html b/docs/Pointer.js.html index f6b9911c5..e0ca5c8d9 100644 --- a/docs/Pointer.js.html +++ b/docs/Pointer.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,10 +551,9 @@ */ /** -* Phaser - Pointer constructor. +* A Pointer object is used by the Mouse, Touch and MSPoint managers and represents a single finger on the touch screen. * * @class Phaser.Pointer -* @classdesc A Pointer object is used by the Mouse, Touch and MSPoint managers and represents a single finger on the touch screen. * @constructor * @param {Phaser.Game} game - A reference to the currently running game. * @param {number} id - The ID of the Pointer object within the game. Each game can have up to 10 active pointers. @@ -1326,7 +1333,7 @@ Object.defineProperty(Phaser.Pointer.prototype, "worldY", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Polygon.js.html b/docs/Polygon.js.html index ee289bbd8..c3abf8317 100644 --- a/docs/Polygon.js.html +++ b/docs/Polygon.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -550,9 +558,8 @@ * arguments passed can be flat x,y values e.g. `new Phaser.Polygon(x,y, x,y, x,y, ...)` where `x` and `y` are numbers. * * @class Phaser.Polygon -* @classdesc The polygon represents a list of orderded points in space * @constructor -* @param {Array<Phaser.Point>|Array<number>} points - The array of Points. +* @param {Phaser.Point[]|number[]} points - The array of Points. */ Phaser.Polygon = function (points) { @@ -752,7 +759,7 @@ PIXI.Polygon = Phaser.Polygon; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/PrismaticConstraint.js.html b/docs/PrismaticConstraint.js.html index 81d0dbc04..1a455760f 100644 --- a/docs/PrismaticConstraint.js.html +++ b/docs/PrismaticConstraint.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * Connects two bodies at given offset points, letting them rotate relative to each other around this point. * * @class Phaser.Physics.P2.PrismaticConstraint -* @classdesc Physics PrismaticConstraint Constructor * @constructor * @param {Phaser.Physics.P2} world - A reference to the P2 World. * @param {p2.Body} bodyA - First connected body. @@ -607,7 +614,7 @@ Phaser.Physics.P2.PrismaticConstraint.prototype.constructor = Phaser.Physics.P2. Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/QuadTree.js.html b/docs/QuadTree.js.html index 4a3384ce2..ce3cb43f5 100644 --- a/docs/QuadTree.js.html +++ b/docs/QuadTree.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -537,55 +545,18 @@
    /**
    + * @author       Timo Hausmann
      * @author       Richard Davey <rich@photonstorm.com>
      * @copyright    2014 Photon Storm Ltd.
      * @license      {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License}
      */
     
     /**
    -* Javascript QuadTree
    -* @version 1.0
    -* @author Timo Hausmann
    -*
    -* @version 1.3, March 11th 2014
    -* @author Richard Davey
    -* The original code was a conversion of the Java code posted to GameDevTuts. However I've tweaked
    -* it massively to add node indexing, removed lots of temp. var creation and significantly
    -* increased performance as a result.
    -*
    -* Original version at https://github.com/timohausmann/quadtree-js/
    -*/
    -
    -/**
    -* @copyright © 2012 Timo Hausmann
    -*
    -* Permission is hereby granted, free of charge, to any person obtaining
    -* a copy of this software and associated documentation files (the
    -* "Software"), to deal in the Software without restriction, including
    -* without limitation the rights to use, copy, modify, merge, publish,
    -* distribute, sublicense, and/or sell copies of the Software, and to
    -* permit persons to whom the Software is furnished to do so, subject to
    -* the following conditions:
    -*
    -* The above copyright notice and this permission notice shall be
    -* included in all copies or substantial portions of the Software.
    -*
    -* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
    -* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
    -* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
    -* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
    -* LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
    -* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
    -* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
    -*/
    -
    -/**
    -* QuadTree Constructor
    -*
    -* @class Phaser.QuadTree
    -* @classdesc A QuadTree implementation. The original code was a conversion of the Java code posted to GameDevTuts.
    +* A QuadTree implementation. The original code was a conversion of the Java code posted to GameDevTuts.
     * However I've tweaked it massively to add node indexing, removed lots of temp. var creation and significantly increased performance as a result.
     * Original version at https://github.com/timohausmann/quadtree-js/
    +*
    +* @class Phaser.QuadTree
     * @constructor
     * @param {number} x - The top left coordinate of the quadtree.
     * @param {number} y - The top left coordinate of the quadtree.
    @@ -889,6 +860,42 @@ Phaser.QuadTree.prototype = {
     };
     
     Phaser.QuadTree.prototype.constructor = Phaser.QuadTree;
    +
    +/**
    +* Javascript QuadTree
    +* @version 1.0
    +*
    +* @version 1.3, March 11th 2014
    +* @author Richard Davey
    +* The original code was a conversion of the Java code posted to GameDevTuts. However I've tweaked
    +* it massively to add node indexing, removed lots of temp. var creation and significantly
    +* increased performance as a result.
    +*
    +* Original version at https://github.com/timohausmann/quadtree-js/
    +*/
    +
    +/**
    +* @copyright © 2012 Timo Hausmann
    +*
    +* Permission is hereby granted, free of charge, to any person obtaining
    +* a copy of this software and associated documentation files (the
    +* "Software"), to deal in the Software without restriction, including
    +* without limitation the rights to use, copy, modify, merge, publish,
    +* distribute, sublicense, and/or sell copies of the Software, and to
    +* permit persons to whom the Software is furnished to do so, subject to
    +* the following conditions:
    +*
    +* The above copyright notice and this permission notice shall be
    +* included in all copies or substantial portions of the Software.
    +*
    +* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
    +* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
    +* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
    +* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
    +* LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
    +* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
    +* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
    +*/
     
    @@ -910,7 +917,7 @@ Phaser.QuadTree.prototype.constructor = Phaser.QuadTree; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/RandomDataGenerator.js.html b/docs/RandomDataGenerator.js.html index 647abd8c0..b1c4ca7c6 100644 --- a/docs/RandomDataGenerator.js.html +++ b/docs/RandomDataGenerator.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -545,15 +553,13 @@ */ /** -* Phaser.RandomDataGenerator constructor. -* -* @class Phaser.RandomDataGenerator -* @classdesc An extremely useful repeatable random data generator. Access it via Phaser.Game.rnd +* An extremely useful repeatable random data generator. * Based on Nonsense by Josh Faul https://github.com/jocafa/Nonsense. * Random number generator from http://baagoe.org/en/wiki/Better_random_numbers_for_javascript * +* @class Phaser.RandomDataGenerator * @constructor -* @param {array} seeds +* @param {array} [seeds] - An array of values to use as the seed. */ Phaser.RandomDataGenerator = function (seeds) { @@ -852,7 +858,7 @@ Phaser.RandomDataGenerator.prototype.constructor = Phaser.RandomDataGenerator; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Rectangle.js.html b/docs/Rectangle.js.html index 5d5d2794f..f11fdaedf 100644 --- a/docs/Rectangle.js.html +++ b/docs/Rectangle.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,7 +551,8 @@ */ /** -* Creates a new Rectangle object with the top-left corner specified by the x and y parameters and with the specified width and height parameters. If you call this function without parameters, a Rectangle with x, y, width, and height properties set to 0 is created. +* Creates a new Rectangle object with the top-left corner specified by the x and y parameters and with the specified width and height parameters. +* If you call this function without parameters, a Rectangle with x, y, width, and height properties set to 0 is created. * * @class Phaser.Rectangle * @constructor @@ -551,7 +560,6 @@ * @param {number} y - The y coordinate of the top-left corner of the Rectangle. * @param {number} width - The width of the Rectangle. Should always be either zero or a positive value. * @param {number} height - The height of the Rectangle. Should always be either zero or a positive value. -* @return {Phaser.Rectangle} This Rectangle object. */ Phaser.Rectangle = function (x, y, width, height) { @@ -634,7 +642,7 @@ Phaser.Rectangle.prototype = { /** * Centers this Rectangle so that the center coordinates match the given x and y values. - * + * * @method Phaser.Rectangle#centerOn * @param {number} x - The x coordinate to place the center of the Rectangle at. * @param {number} y - The y coordinate to place the center of the Rectangle at. @@ -807,7 +815,7 @@ Phaser.Rectangle.prototype = { /** * Determines whether the coordinates given intersects (overlaps) with this Rectangle. - * + * * @method Phaser.Rectangle#intersectsRaw * @param {number} left - The x coordinate of the left of the area. * @param {number} right - The right coordinate of the area. @@ -1020,7 +1028,7 @@ Object.defineProperty(Phaser.Rectangle.prototype, "centerY", { /** * A random value between the left and right values (inclusive) of the Rectangle. -* +* * @name Phaser.Rectangle#randomX * @property {number} randomX - A random value between the left and right values (inclusive) of the Rectangle. */ @@ -1036,7 +1044,7 @@ Object.defineProperty(Phaser.Rectangle.prototype, "randomX", { /** * A random value between the top and bottom values (inclusive) of the Rectangle. -* +* * @name Phaser.Rectangle#randomY * @property {number} randomY - A random value between the top and bottom values (inclusive) of the Rectangle. */ @@ -1376,6 +1384,47 @@ Phaser.Rectangle.union = function (a, b, output) { }; +/** +* Calculates the Axis Aligned Bounding Box (or aabb) from an array of points. +* +* @method Phaser.Rectangle#aabb +* @param {Phaser.Point[]} points - The array of one or more points. +* @param {Phaser.Rectangle} [out] - Optional Rectangle to store the value in, if not supplied a new Rectangle object will be created. +* @return {Phaser.Rectangle} The new Rectangle object. +* @static +*/ +Phaser.Rectangle.aabb = function(points, out) { + + if (typeof out === "undefined") { + out = new Phaser.Rectangle(); + } + + var xMax = Number.MIN_VALUE, + xMin = Number.MAX_VALUE, + yMax = Number.MIN_VALUE, + yMin = Number.MAX_VALUE; + + points.forEach(function(point) { + if (point.x > xMax) { + xMax = point.x; + } + if (point.x < xMin) { + xMin = point.x; + } + + if (point.y > yMax) { + yMax = point.y; + } + if (point.y < yMin) { + yMin = point.y; + } + }); + + out.setTo(xMin, yMin, xMax - xMin, yMax - yMin); + + return out; +}; + // Because PIXI uses its own Rectangle, we'll replace it with ours to avoid duplicating code or confusion. PIXI.Rectangle = Phaser.Rectangle; PIXI.EmptyRectangle = new Phaser.Rectangle(0, 0, 0, 0); @@ -1400,7 +1449,7 @@ PIXI.EmptyRectangle = new Phaser.Rectangle(0, 0, 0, 0); Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/RenderTexture.js.html b/docs/RenderTexture.js.html index afb75ede0..227cb0962 100644 --- a/docs/RenderTexture.js.html +++ b/docs/RenderTexture.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -548,6 +556,7 @@ * * @class Phaser.RenderTexture * @constructor +* @extends PIXI.RenderTexture * @param {Phaser.Game} game - Current game instance. * @param {string} key - Internal Phaser reference key for the render texture. * @param {number} [width=100] - The width of the render texture. @@ -644,7 +653,7 @@ Phaser.RenderTexture.prototype.renderXY = function (displayObject, x, y, clear) Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/RequestAnimationFrame.js.html b/docs/RequestAnimationFrame.js.html index b93f3f589..cfb5fa8d5 100644 --- a/docs/RequestAnimationFrame.js.html +++ b/docs/RequestAnimationFrame.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -723,7 +731,7 @@ Phaser.RequestAnimationFrame.prototype.constructor = Phaser.RequestAnimationFram Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/RetroFont.js.html b/docs/RetroFont.js.html index a4921fb66..0f5bfd8ca 100644 --- a/docs/RetroFont.js.html +++ b/docs/RetroFont.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,6 +551,9 @@ */ /** +* A Retro Font is similar to a BitmapFont, in that it uses a texture to render the text. However unlike a BitmapFont every character in a RetroFont +* is the same size. This makes it similar to a sprite sheet. You typically find font sheets like this from old 8/16-bit games and demos. +* * @class Phaser.RetroFont * @extends Phaser.RenderTexture * @constructor @@ -1171,7 +1182,7 @@ Object.defineProperty(Phaser.RetroFont.prototype, "smoothed", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/RevoluteConstraint.js.html b/docs/RevoluteConstraint.js.html index d6191a55f..3270f95b1 100644 --- a/docs/RevoluteConstraint.js.html +++ b/docs/RevoluteConstraint.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -547,7 +555,6 @@ * The pivot points are given in world (pixel) coordinates. * * @class Phaser.Physics.P2.RevoluteConstraint -* @classdesc Physics RevoluteConstraint Constructor * @constructor * @param {Phaser.Physics.P2} world - A reference to the P2 World. * @param {p2.Body} bodyA - First connected body. @@ -609,7 +616,7 @@ Phaser.Physics.P2.RevoluteConstraint.prototype.constructor = Phaser.Physics.P2.R Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Rope.js.html b/docs/Rope.js.html index 932160635..be04ec218 100644 --- a/docs/Rope.js.html +++ b/docs/Rope.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -548,6 +556,7 @@ * * @class Phaser.Rope * @constructor +* @extends Pixi.Rope * @param {Phaser.Game} game - A reference to the currently running game. * @param {number} x - The x coordinate (in world space) to position the Rope at. * @param {number} y - The y coordinate (in world space) to position the Rope at. @@ -925,6 +934,10 @@ Phaser.Rope.prototype.setFrame = function(frame) { this.texture.frame.width = frame.sourceSizeW; this.texture.frame.height = frame.sourceSizeH; } + else if (!frame.trimmed && this.texture.trim) + { + this.texture.trim = null; + } if (this.game.renderType === Phaser.WEBGL) { @@ -1384,7 +1397,7 @@ Object.defineProperty(Phaser.Rope.prototype, "destroyPhase", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/RotationalSpring.js.html b/docs/RotationalSpring.js.html index d846392ea..f969600c9 100644 --- a/docs/RotationalSpring.js.html +++ b/docs/RotationalSpring.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * Creates a rotational spring, connecting two bodies. A spring can have a resting length, a stiffness and damping. * * @class Phaser.Physics.P2.RotationalSpring -* @classdesc Physics Spring Constructor * @constructor * @param {Phaser.Physics.P2} world - A reference to the P2 World. * @param {p2.Body} bodyA - First connected body. @@ -613,7 +620,7 @@ Phaser.Physics.P2.Spring.prototype.constructor = Phaser.Physics.P2.Spring; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/ScaleManager.js.html b/docs/ScaleManager.js.html index 225b634bb..c29245fd4 100644 --- a/docs/ScaleManager.js.html +++ b/docs/ScaleManager.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1718,7 +1726,7 @@ Object.defineProperty(Phaser.ScaleManager.prototype, "isLandscape", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Signal.js.html b/docs/Signal.js.html index 53e1a04a0..3965b32d6 100644 --- a/docs/Signal.js.html +++ b/docs/Signal.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -537,15 +545,16 @@
    /**
    +* @author       Miller Medeiros http://millermedeiros.github.com/js-signals/
     * @author       Richard Davey <rich@photonstorm.com>
     * @copyright    2014 Photon Storm Ltd.
     * @license      {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License}
     */
     
     /**
    +* A Signal is used for object communication via a custom broadcaster instead of Events.
    +* 
     * @class Phaser.Signal
    -* @classdesc A Signal is used for object communication via a custom broadcaster instead of Events.
    -* @author Miller Medeiros http://millermedeiros.github.com/js-signals/
     * @constructor
     */
     Phaser.Signal = function () {
    @@ -929,7 +938,7 @@ Phaser.Signal.prototype.constructor = Phaser.Signal;
     					
     		
     		Documentation generated by JSDoc 3.3.0-dev
    -		on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template.
    +		on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template.
     		
     				
     			
    diff --git a/docs/SignalBinding.js.html b/docs/SignalBinding.js.html
    index 84ebaf1e0..44ea43f7a 100644
    --- a/docs/SignalBinding.js.html
    +++ b/docs/SignalBinding.js.html
    @@ -58,6 +58,10 @@
     							ArrayList
     						
     						
    +						
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -537,18 +545,18 @@
    /**
    +* @author       Miller Medeiros http://millermedeiros.github.com/js-signals/
     * @author       Richard Davey <rich@photonstorm.com>
     * @copyright    2014 Photon Storm Ltd.
     * @license      {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License}
     */
     
     /**
    -* @class Phaser.SignalBinding
    -* @classdesc Object that represents a binding between a Signal and a listener function.
    +* Object that represents a binding between a Signal and a listener function.
     * This is an internal constructor and shouldn't be created directly.
     * Inspired by Joa Ebert AS3 SignalBinding and Robert Penner's Slot classes.
    -*
    -* @author Miller Medeiros http://millermedeiros.github.com/js-signals/
    +* 
    +* @class Phaser.SignalBinding
     * @constructor
     * @param {Phaser.Signal} signal - Reference to Signal object that listener is currently bound to.
     * @param {function} listener - Handler function bound to the signal.
    @@ -716,7 +724,7 @@ Phaser.SignalBinding.prototype.constructor = Phaser.SignalBinding;
     					
     		
     		Documentation generated by JSDoc 3.3.0-dev
    -		on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template.
    +		on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template.
     		
     				
     			
    diff --git a/docs/SinglePad.js.html b/docs/SinglePad.js.html
    index 6da504755..70a06c9f9 100644
    --- a/docs/SinglePad.js.html
    +++ b/docs/SinglePad.js.html
    @@ -58,6 +58,10 @@
     							ArrayList
     						
     						
    +						
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -544,8 +552,9 @@ */ /** +* A single Phaser Gamepad +* * @class Phaser.SinglePad -* @classdesc A single Phaser Gamepad * @constructor * @param {Phaser.Game} game - Current game instance. * @param {Object} padParent - The parent Phaser.Gamepad object (all gamepads reside under this) @@ -1110,7 +1119,7 @@ Phaser.SinglePad.prototype.constructor = Phaser.SinglePad; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Sound.js.html b/docs/Sound.js.html index 3ebed6422..1c730f339 100644 --- a/docs/Sound.js.html +++ b/docs/Sound.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * The Sound class constructor. * * @class Phaser.Sound -* @classdesc The Sound class * @constructor * @param {Phaser.Game} game - Reference to the current game instance. * @param {string} key - Asset key for the sound. @@ -676,6 +683,12 @@ Phaser.Sound = function (game, key, volume, loop, connect) { */ this.override = false; + /** + * @property {boolean} allowMultiple - This will allow you to have multiple instances of this Sound playing at once. This is only useful when running under Web Audio, and we recommend you implement a local pooling system to not flood the sound channels. + * @default + */ + this.allowMultiple = false; + /** * @property {boolean} usingWebAudio - true if this sound is being played with Web Audio. * @readonly @@ -781,6 +794,11 @@ Phaser.Sound = function (game, key, volume, loop, connect) { */ this.onMarkerComplete = new Phaser.Signal(); + /** + * @property {Phaser.Signal} onFadeComplete - The onFadeComplete event is dispatched when this sound finishes fading either in or out. + */ + this.onFadeComplete = new Phaser.Signal(); + /** * @property {number} _volume - The global audio volume. A value between 0 (silence) and 1 (full volume). * @private @@ -978,13 +996,13 @@ Phaser.Sound.prototype = { if (typeof marker === 'undefined') { marker = ''; } if (typeof forceRestart === 'undefined') { forceRestart = true; } - if (this.isPlaying && !forceRestart && !this.override) + if (this.isPlaying && !this.allowMultiple && !forceRestart && !this.override) { // Use Restart instead return this; } - if (this.isPlaying && (this.override || forceRestart)) + if (this.isPlaying && !this.allowMultiple && (this.override || forceRestart)) { if (this.usingWebAudio) { @@ -1314,6 +1332,74 @@ Phaser.Sound.prototype = { }, + /** + * Starts this sound playing (or restarts it if already doing so) and sets the volume to zero. + * Then increases the volume from 0 to 1 over the duration specified. + * At the end of the fade Sound.onFadeComplete is dispatched with this Sound object as the first parameter, + * and the final volume (1) as the second parameter. + * + * @method Phaser.Sound#fadeIn + * @param {number} [duration=1000] - The time in milliseconds during which the Sound should fade in. + * @param {boolean} [loop=false] - Should the Sound be set to loop? Note that this doesn't cause the fade to repeat. + */ + fadeIn: function (duration, loop) { + + if (typeof duration === 'undefined') { duration = 1000; } + if (typeof loop === 'undefined') { loop = false; } + + if (this.paused) + { + return; + } + + this.play('', 0, 0, loop); + + var tween = this.game.add.tween(this).to( { volume: 1 }, duration, Phaser.Easing.Linear.None, true); + + tween.onComplete.add(this.fadeComplete, this); + + }, + + /** + * Decreases the volume of this Sound from its current value to 0 over the duration specified. + * At the end of the fade Sound.onFadeComplete is dispatched with this Sound object as the first parameter, + * and the final volume (0) as the second parameter. + * + * @method Phaser.Sound#fadeOut + * @param {number} [duration=1000] - The time in milliseconds during which the Sound should fade out. + */ + fadeOut: function (duration) { + + if (typeof duration === 'undefined') { duration = 1000; } + + if (!this.isPlaying || this.paused || this.volume <= 0) + { + return; + } + + var tween = this.game.add.tween(this).to( { volume: 0 }, duration, Phaser.Easing.Linear.None, true); + + tween.onComplete.add(this.fadeComplete, this); + + }, + + /** + * Internal handler for Sound.fadeIn and Sound.fadeOut. + * + * @method Phaser.Sound#fadeComplete + * @private + */ + fadeComplete: function () { + + this.onFadeComplete.dispatch(this, this.volume); + + if (this.volume === 0) + { + this.stop(); + } + + }, + /** * Destroys this sound and all associated events and removes it from the SoundManager. * @@ -1481,7 +1567,7 @@ Object.defineProperty(Phaser.Sound.prototype, "volume", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/SoundManager.js.html b/docs/SoundManager.js.html index 9c48e8546..a2d9623f7 100644 --- a/docs/SoundManager.js.html +++ b/docs/SoundManager.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,14 +551,12 @@ */ /** -* Sound Manager constructor. * The Sound Manager is responsible for playing back audio via either the Legacy HTML Audio tag or via Web Audio if the browser supports it. * Note: On Firefox 25+ on Linux if you have media.gstreamer disabled in about:config then it cannot play back mp3 or m4a files. * The audio file type and the encoding of those files are extremely important. Not all browsers can play all audio formats. * There is a good guide to what's supported here: http://hpr.dogphilosophy.net/test/ * * @class Phaser.SoundManager -* @classdesc Phaser Sound Manager. * @constructor * @param {Phaser.Game} game reference to the current game instance. */ @@ -906,6 +912,21 @@ Phaser.SoundManager.prototype = { }, + /** + * Adds a new AudioSprite into the SoundManager. + * + * @method Phaser.SoundManager#addSprite + * @param {string} key - Asset key for the sound. + * @return {Phaser.AudioSprite} The new AudioSprite instance. + */ + addSprite: function(key) { + + var audioSprite = new Phaser.AudioSprite(this.game, key); + + return audioSprite; + + }, + /** * Removes a Sound from the SoundManager. The removed Sound is destroyed before removal. * @@ -1169,7 +1190,7 @@ Object.defineProperty(Phaser.SoundManager.prototype, "volume", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Spring.js.html b/docs/Spring.js.html index c331cfd53..2b333b0ae 100644 --- a/docs/Spring.js.html +++ b/docs/Spring.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * Creates a linear spring, connecting two bodies. A spring can have a resting length, a stiffness and damping. * * @class Phaser.Physics.P2.Spring -* @classdesc Physics Spring Constructor * @constructor * @param {Phaser.Physics.P2} world - A reference to the P2 World. * @param {p2.Body} bodyA - First connected body. @@ -634,7 +641,7 @@ Phaser.Physics.P2.Spring.prototype.constructor = Phaser.Physics.P2.Spring; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Sprite.js.html b/docs/Sprite.js.html index 0a5eb1c71..87a627f63 100644 --- a/docs/Sprite.js.html +++ b/docs/Sprite.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,14 +551,13 @@ */ /** -* @class Phaser.Sprite -* -* @classdesc Create a new `Sprite` object. Sprites are the lifeblood of your game, used for nearly everything visual. +* Sprites are the lifeblood of your game, used for nearly everything visual. * * At its most basic a Sprite consists of a set of coordinates and a texture that is rendered to the canvas. * They also contain additional properties allowing for physics motion (via Sprite.body), input handling (via Sprite.input), * events (via Sprite.events), animation (via Sprite.animations), camera culling and more. Please see the Examples for use cases. * +* @class Phaser.Sprite * @constructor * @extends PIXI.Sprite * @param {Phaser.Game} game - A reference to the currently running game. @@ -918,6 +925,11 @@ Phaser.Sprite.prototype.loadTexture = function (key, frame, stopAnimation) { { // This works from a reference, which probably isn't what we need here this.setTexture(key.texture); + + if (this.game.cache.getFrameData(key.key, Phaser.Cache.BITMAPDATA)) + { + setFrame = !this.animations.loadFrameData(this.game.cache.getFrameData(key.key, Phaser.Cache.BITMAPDATA), frame); + } } else if (key instanceof PIXI.Texture) { @@ -997,6 +1009,10 @@ Phaser.Sprite.prototype.setFrame = function(frame) { this.texture.frame.width = frame.sourceSizeW; this.texture.frame.height = frame.sourceSizeH; } + else if (!frame.trimmed && this.texture.trim) + { + this.texture.trim = null; + } if (this.cropRect) { @@ -1775,7 +1791,7 @@ Object.defineProperty(Phaser.Sprite.prototype, "destroyPhase", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/SpriteBatch.js.html b/docs/SpriteBatch.js.html index c8c775925..9f79f50f7 100644 --- a/docs/SpriteBatch.js.html +++ b/docs/SpriteBatch.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,13 +551,11 @@ */ /** -* Phaser SpriteBatch constructor. * The SpriteBatch class is a really fast version of the DisplayObjectContainer built purely for speed, so use when you need a lot of sprites or particles. * It's worth mentioning that by default sprite batches are used through-out the renderer, so you only really need to use a SpriteBatch if you have over * 1000 sprites that all share the same texture (or texture atlas). It's also useful if running in Canvas mode and you have a lot of un-rotated or un-scaled * Sprites as it skips all of the Canvas setTransform calls, which helps performance, especially on mobile devices. * -* @classdesc The SpriteBatch class is a really fast version of the DisplayObjectContainer built solely for speed, so use when you need a lot of sprites or particles. * @class Phaser.SpriteBatch * @extends Phaser.Group * @constructor @@ -598,7 +604,7 @@ Phaser.SpriteBatch.prototype.constructor = Phaser.SpriteBatch; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Stage.js.html b/docs/Stage.js.html index a158c9e75..9a3001656 100644 --- a/docs/Stage.js.html +++ b/docs/Stage.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -544,7 +552,7 @@ /** * The Stage controls root level display objects upon which everything is displayed. -* It also handles browser visibility handling and the pausing due to loss of focus. +* It also handles browser visibility handling and the pausing due to loss of focus. * * @class Phaser.Stage * @extends PIXI.Stage @@ -938,7 +946,7 @@ Object.defineProperty(Phaser.Stage.prototype, "smoothed", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/State.js.html b/docs/State.js.html index dd5571940..f3199465e 100644 --- a/docs/State.js.html +++ b/docs/State.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -753,7 +761,7 @@ Phaser.State.prototype.constructor = Phaser.State; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/StateManager.js.html b/docs/StateManager.js.html index c11c0b0a8..d08200c3b 100644 --- a/docs/StateManager.js.html +++ b/docs/StateManager.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -680,18 +688,15 @@ Phaser.StateManager.prototype = { */ boot: function () { + // console.log('StateManager boot'); + this.game.onPause.add(this.pause, this); this.game.onResume.add(this.resume, this); this.game.load.onLoadComplete.add(this.loadComplete, this); if (this._pendingState !== null) { - if (typeof this._pendingState === 'string') - { - // State was already added, so just start it - this.start(this._pendingState, false, false); - } - else + if (typeof this._pendingState !== 'string') { this.add('default', this._pendingState, true); } @@ -788,12 +793,17 @@ Phaser.StateManager.prototype = { */ start: function (key, clearWorld, clearCache) { + // console.log('-----------------------------------------------------------------------------------------'); + // console.log('START:', key); + if (typeof clearWorld === "undefined") { clearWorld = true; } if (typeof clearCache === "undefined") { clearCache = false; } if (this.checkState(key)) { // Place the state in the queue. It will be started the next time the game loop starts. + // console.log('set to pending', key); + this._pendingState = key; this._clearWorld = clearWorld; this._clearCache = clearCache; @@ -848,34 +858,52 @@ Phaser.StateManager.prototype = { if (this._pendingState && this.game.isBooted) { + // console.log('preUpdate - has pending:', this._pendingState, 'current:', this.current); + // Already got a state running? this.clearCurrentState(); this.setCurrentState(this._pendingState); + if (this.current !== this._pendingState) + { + // console.log('-> init called StateManager.start(', this._pendingState, ') so bail out'); + return; + } + else + { + this._pendingState = null; + // console.log('pending nulled'); + } + + // If StateManager.start has been called from the init of a State that ALSO has a preload, then + // onPreloadCallback will be set, but must be ignored if (this.onPreloadCallback) { + // console.log('-> preload (', this.current, ')'); + this.game.load.reset(); this.onPreloadCallback.call(this.callbackContext, this.game); // Is the loader empty? if (this.game.load.totalQueuedFiles() === 0 && this.game.load.totalQueuedPacks() === 0) { + // console.log('loadComplete from empty preloader', this.current); this.loadComplete(); } else { // Start the loader going as we have something in the queue + // console.log('load start', this.current); this.game.load.start(); } } else { // No init? Then there was nothing to load either + // console.log('loadComplete from no preloader', this.current); this.loadComplete(); } - - this._pendingState = null; } }, @@ -888,10 +916,15 @@ Phaser.StateManager.prototype = { */ clearCurrentState: function () { + // console.log('clearCurrentState', this.current); + if (this.current) { + // console.log('removing all', this.current); + if (this.onShutDownCallback) { + // console.log('-> shutdown (', this.current, ')'); this.onShutDownCallback.call(this.callbackContext, this.game); } @@ -934,6 +967,8 @@ Phaser.StateManager.prototype = { */ checkState: function (key) { + // console.log('checking', key); + if (this.states[key]) { var valid = false; @@ -989,6 +1024,39 @@ Phaser.StateManager.prototype = { }, + /** + * Nulls all State level Phaser properties, including a reference to Game. + * + * @method Phaser.StateManager#unlink + * @param {string} key - State key. + * @protected + */ + unlink: function (key) { + + if (this.states[key]) + { + this.states[key].game = null; + this.states[key].add = null; + this.states[key].make = null; + this.states[key].camera = null; + this.states[key].cache = null; + this.states[key].input = null; + this.states[key].load = null; + this.states[key].math = null; + this.states[key].sound = null; + this.states[key].scale = null; + this.states[key].state = null; + this.states[key].stage = null; + this.states[key].time = null; + this.states[key].tweens = null; + this.states[key].world = null; + this.states[key].particles = null; + this.states[key].rnd = null; + this.states[key].physics = null; + } + + }, + /** * Sets the current State. Should not be called directly (use StateManager.start) * @@ -998,6 +1066,8 @@ Phaser.StateManager.prototype = { */ setCurrentState: function (key) { + // console.log('setCurrentState', key); + this.callbackContext = this.states[key]; this.link(key); @@ -1023,9 +1093,16 @@ Phaser.StateManager.prototype = { this.current = key; this._created = false; + // At this point key and pendingState should equal each other + // console.log('-> init (', key, ')', this._pendingState); + this.onInitCallback.apply(this.callbackContext, this._args); - this._args = []; + // If they no longer do then the init callback hit StateManager.start + if (key === this._pendingState) + { + this._args = []; + } }, @@ -1046,8 +1123,11 @@ Phaser.StateManager.prototype = { */ loadComplete: function () { + // console.log('loadComplete'); + if (this._created === false && this.onCreateCallback) { + // console.log('-> create (', this.current, ')'); this._created = true; this.onCreateCallback.call(this.callbackContext, this.game); } @@ -1235,7 +1315,7 @@ Phaser.StateManager.prototype.constructor = Phaser.StateManager; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Text.js.html b/docs/Text.js.html index f8097b28e..e201ff1da 100644 --- a/docs/Text.js.html +++ b/docs/Text.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -635,6 +643,12 @@ Phaser.Text = function (game, x, y, text, style) { */ this._lineSpacing = 0; + /** + * @property {number} _charCount - Internal character counter used by the text coloring. + * @private + */ + this._charCount = 0; + /** * @property {Phaser.Events} events - The Events you can subscribe to that are dispatched when certain things happen on this Sprite or its components. */ @@ -650,6 +664,11 @@ Phaser.Text = function (game, x, y, text, style) { */ this.cameraOffset = new Phaser.Point(); + /** + * @property {array} colors - An array of the color values as specified by `Text.addColor`. + */ + this.colors = []; + this.setStyle(style); PIXI.Text.call(this, text, this.style); @@ -841,14 +860,14 @@ Phaser.Text.prototype.setShadow = function (x, y, color, blur) { * Set the style of the text by passing a single style object to it. * * @method Phaser.Text.prototype.setStyle -* @param [style] {Object} The style parameters -* @param [style.font='bold 20pt Arial'] {String} The style and size of the font -* @param [style.fill='black'] {Object} A canvas fillstyle that will be used on the text eg 'red', '#00FF00' -* @param [style.align='left'] {String} Alignment for multiline text ('left', 'center' or 'right'), does not affect single line text -* @param [style.stroke='black'] {String} A canvas fillstyle that will be used on the text stroke eg 'blue', '#FCFF00' -* @param [style.strokeThickness=0] {Number} A number that represents the thickness of the stroke. Default is 0 (no stroke) -* @param [style.wordWrap=false] {Boolean} Indicates if word wrap should be used -* @param [style.wordWrapWidth=100] {Number} The width at which text will wrap +* @param {Object} [style] - The style properties to be set on the Text. +* @param {string} [style.font='bold 20pt Arial'] - The style and size of the font. +* @param {string} [style.fill='black'] - A canvas fillstyle that will be used on the text eg 'red', '#00FF00'. +* @param {string} [style.align='left'] - Alignment for multiline text ('left', 'center' or 'right'), does not affect single line text. +* @param {string} [style.stroke='black'] - A canvas stroke style that will be used on the text stroke eg 'blue', '#FCFF00'. +* @param {number} [style.strokeThickness=0] - A number that represents the thickness of the stroke. Default is 0 (no stroke). +* @param {boolean} [style.wordWrap=false] - Indicates if word wrap should be used. +* @param {number} [style.wordWrapWidth=100] - The width in pixels at which text will wrap. */ Phaser.Text.prototype.setStyle = function (style) { @@ -931,6 +950,8 @@ Phaser.Text.prototype.updateText = function () { this.context.lineCap = 'round'; this.context.lineJoin = 'round'; + this._charCount = 0; + //draw lines line by line for (i = 0; i < lines.length; i++) { @@ -947,24 +968,91 @@ Phaser.Text.prototype.updateText = function () { linePosition.y += this._lineSpacing; - if (this.style.stroke && this.style.strokeThickness) + if (this.colors.length > 0) { - this.context.strokeText(lines[i], linePosition.x, linePosition.y); + this.updateLine(lines[i], linePosition.x, linePosition.y); } - - if (this.style.fill) + else { - this.context.fillText(lines[i], linePosition.x, linePosition.y); + if (this.style.stroke && this.style.strokeThickness) + { + this.context.strokeText(lines[i], linePosition.x, linePosition.y); + } + + if (this.style.fill) + { + this.context.fillText(lines[i], linePosition.x, linePosition.y); + } } } this.updateTexture(); }; +Phaser.Text.prototype.updateLine = function (line, x, y) { + + for (var i = 0; i < line.length; i++) + { + var letter = line[i]; + + if (this.colors[this._charCount]) + { + this.context.fillStyle = this.colors[this._charCount]; + this.context.strokeStyle = this.colors[this._charCount]; + } + + if (this.style.stroke && this.style.strokeThickness) + { + this.context.strokeText(letter, x, y); + } + + if (this.style.fill) + { + this.context.fillText(letter, x, y); + } + + x += this.context.measureText(letter).width; + + this._charCount++; + } + +}; + +/** +* Clears any previously set color stops. +* +* @method Phaser.Text.prototype.clearColors +*/ +Phaser.Text.prototype.clearColors = function () { + + this.colors = []; + this.dirty = true; + +}; + +/** +* This method allows you to set specific colors within the Text. +* It works by taking a color value, which is a typical HTML string such as `#ff0000` or `rgb(255,0,0)` and a position. +* The position value is the index of the character in the Text string to start applying this color to. +* Once set the color remains in use until either another color or the end of the string is encountered. +* For example if the Text was `Photon Storm` and you did `Text.addColor('#ffff00', 6)` it would color in the word `Storm` in yellow. +* +* @method Phaser.Text.prototype.addColor +* @param {string} color - A canvas fillstyle that will be used on the text eg `red`, `#00FF00`, `rgba()`. +* @param {number} position - The index of the character in the string to start applying this color value from. +*/ +Phaser.Text.prototype.addColor = function (color, position) { + + this.colors[position] = color; + this.dirty = true; + +}; + /** * Greedy wrapping algorithm that will wrap words as the line grows longer than its horizontal bounds. * * @method Phaser.Text.prototype.runWordWrap +* @param {string} text - The text to perform word wrap detection against. * @private */ Phaser.Text.prototype.runWordWrap = function (text) { @@ -1045,7 +1133,11 @@ Object.defineProperty(Phaser.Text.prototype, 'text', { { this._text = value.toString() || ' '; this.dirty = true; - this.updateTransform(); + + if (this.parent) + { + this.updateTransform(); + } } } @@ -1069,7 +1161,11 @@ Object.defineProperty(Phaser.Text.prototype, 'font', { this._font = value.trim(); this.style.font = this._fontWeight + ' ' + this._fontSize + "px '" + this._font + "'"; this.dirty = true; - this.updateTransform(); + + if (this.parent) + { + this.updateTransform(); + } } } @@ -1095,7 +1191,11 @@ Object.defineProperty(Phaser.Text.prototype, 'fontSize', { this._fontSize = value; this.style.font = this._fontWeight + ' ' + this._fontSize + "px '" + this._font + "'"; this.dirty = true; - this.updateTransform(); + + if (this.parent) + { + this.updateTransform(); + } } } @@ -1119,7 +1219,11 @@ Object.defineProperty(Phaser.Text.prototype, 'fontWeight', { this._fontWeight = value; this.style.font = this._fontWeight + ' ' + this._fontSize + "px '" + this._font + "'"; this.dirty = true; - this.updateTransform(); + + if (this.parent) + { + this.updateTransform(); + } } } @@ -1274,7 +1378,11 @@ Object.defineProperty(Phaser.Text.prototype, 'lineSpacing', { { this._lineSpacing = parseFloat(value); this.dirty = true; - this.updateTransform(); + + if (this.parent) + { + this.updateTransform(); + } } } @@ -1475,7 +1583,7 @@ Object.defineProperty(Phaser.Text.prototype, "destroyPhase", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Tile.js.html b/docs/Tile.js.html index 90384db0b..fcb66fe5f 100644 --- a/docs/Tile.js.html +++ b/docs/Tile.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -552,7 +560,6 @@ * Note: This class could be massively optimised and reduced in size. I leave that challenge up to you. * * @class Phaser.Physics.Ninja.Tile -* @classdesc The Ninja Physics Tile class. Based on code by Metanet Software. * @constructor * @param {Phaser.Physics.Ninja.Body} body - The body that owns this shape. * @param {number} x - The x coordinate to create this shape at. @@ -1329,7 +1336,7 @@ Phaser.Physics.Ninja.Tile.TYPE_HALF = 30; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Tile.js_.html b/docs/Tile.js_.html index 1d55671c0..6b8c82ed5 100644 --- a/docs/Tile.js_.html +++ b/docs/Tile.js_.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,10 +551,9 @@ */ /** -* Create a new `Tile` object. +* A Tile is a representation of a single tile within the Tilemap. * * @class Phaser.Tile -* @classdesc A Tile is a representation of a single tile within the Tilemap. * @constructor * @param {object} layer - The layer in the Tilemap data that this tile belongs to. * @param {number} index - The index of this tile type in the core map data. @@ -955,7 +962,7 @@ Object.defineProperty(Phaser.Tile.prototype, "bottom", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/TileSprite.js.html b/docs/TileSprite.js.html index d11693844..3f57779c1 100644 --- a/docs/TileSprite.js.html +++ b/docs/TileSprite.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -548,6 +556,7 @@ * * @class Phaser.TileSprite * @constructor +* @extends Pixi.TilingSprite * @param {Phaser.Game} game - A reference to the currently running game. * @param {number} x - The x coordinate (in world space) to position the TileSprite at. * @param {number} y - The y coordinate (in world space) to position the TileSprite at. @@ -956,6 +965,10 @@ Phaser.TileSprite.prototype.setFrame = function(frame) { this.texture.frame.width = frame.sourceSizeW; this.texture.frame.height = frame.sourceSizeH; } + else if (!frame.trimmed && this.texture.trim) + { + this.texture.trim = null; + } if (this.game.renderType === Phaser.WEBGL) { @@ -1362,7 +1375,7 @@ Object.defineProperty(Phaser.TileSprite.prototype, "destroyPhase", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Tilemap.js.html b/docs/Tilemap.js.html index 0ba37239f..d3548623c 100644 --- a/docs/Tilemap.js.html +++ b/docs/Tilemap.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -2354,7 +2362,7 @@ Object.defineProperty(Phaser.Tilemap.prototype, "layer", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/TilemapLayer.js.html b/docs/TilemapLayer.js.html index 3254ab0c0..656837d75 100644 --- a/docs/TilemapLayer.js.html +++ b/docs/TilemapLayer.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1369,7 +1377,7 @@ Object.defineProperty(Phaser.TilemapLayer.prototype, "collisionHeight", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/TilemapParser.js.html b/docs/TilemapParser.js.html index 5c7b756ca..befab72cc 100644 --- a/docs/TilemapParser.js.html +++ b/docs/TilemapParser.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1092,7 +1100,7 @@ Phaser.TilemapParser = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Tileset.js.html b/docs/Tileset.js.html index e0a1ff6df..4362ebf68 100644 --- a/docs/Tileset.js.html +++ b/docs/Tileset.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -734,7 +742,7 @@ Phaser.Tileset.prototype.constructor = Phaser.Tileset; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Time.js.html b/docs/Time.js.html index 54b84f173..950092766 100644 --- a/docs/Time.js.html +++ b/docs/Time.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,10 +551,10 @@ */ /** -* Time constructor. +* This is the core internal game clock. +* It manages the elapsed time and calculation of elapsed values, used for game object motion and tweens. * * @class Phaser.Time -* @classdesc This is the core internal game clock. It manages the elapsed time and calculation of elapsed values, used for game object motion and tweens. * @constructor * @param {Phaser.Game} game A reference to the currently running game. */ @@ -957,7 +965,7 @@ Phaser.Time.prototype.constructor = Phaser.Time; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Timer.js.html b/docs/Timer.js.html index 8b3395804..199d04dd9 100644 --- a/docs/Timer.js.html +++ b/docs/Timer.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -548,7 +556,6 @@ * So if you want to fire an event every quarter of a second you'd need to set the delay to 250. * * @class Phaser.Timer -* @classdesc A Timer is a way to create small re-usable or disposable objects that do nothing but wait for a specific moment in time, and then dispatch an event. * @constructor * @param {Phaser.Game} game A reference to the currently running game. * @param {boolean} [autoDestroy=true] - A Timer that is set to automatically destroy itself will do so after all of its events have been dispatched (assuming no looping events). @@ -708,7 +715,7 @@ Phaser.Timer.prototype = { * Creates a new TimerEvent on this Timer. Use the methods add, repeat or loop instead of this. * @method Phaser.Timer#create * @private - * @param {number} delay - The number of milliseconds that should elapse before the Timer will call the given callback. + * @param {number} delay - The number of milliseconds that should elapse before the Timer will call the given callback. This value should be an integer, not a float. Math.round() is applied to it by this method. * @param {boolean} loop - Should the event loop or not? * @param {number} repeatCount - The number of times the event will repeat. * @param {function} callback - The callback that will be called when the Timer event occurs. @@ -718,6 +725,8 @@ Phaser.Timer.prototype = { */ create: function (delay, loop, repeatCount, callback, callbackContext, args) { + delay = Math.round(delay); + var tick = delay; if (this._now === 0) @@ -1279,7 +1288,7 @@ Phaser.Timer.prototype.constructor = Phaser.Timer; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/TimerEvent.js.html b/docs/TimerEvent.js.html index cb8adc62f..93557ccad 100644 --- a/docs/TimerEvent.js.html +++ b/docs/TimerEvent.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,11 +551,11 @@ */ /** -* A TimerEvent is a single event that is processed by a Phaser.Timer. It consists of a delay, which is a value in milliseconds after which the event will fire. +* A TimerEvent is a single event that is processed by a Phaser.Timer. +* It consists of a delay, which is a value in milliseconds after which the event will fire. * It can call a specific callback, passing in optional parameters. * * @class Phaser.TimerEvent -* @classdesc A TimerEvent is a single event that is processed by a Phaser.Timer. It consists of a delay, which is a value in milliseconds after which the event will fire. * @constructor * @param {Phaser.Timer} timer - The Timer object that this TimerEvent belongs to. * @param {number} delay - The delay in ms at which this TimerEvent fires. @@ -630,7 +638,7 @@ Phaser.TimerEvent.prototype.constructor = Phaser.TimerEvent; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Touch.js.html b/docs/Touch.js.html index 2302ea59c..8f97c8b2e 100644 --- a/docs/Touch.js.html +++ b/docs/Touch.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -546,7 +554,6 @@ * Phaser.Touch handles touch events with your game. Note: Android 2.x only supports 1 touch event at once, no multi-touch. * * @class Phaser.Touch -* @classdesc The Touch class handles touch interactions with the game and the resulting Pointer objects. * @constructor * @param {Phaser.Game} game - A reference to the currently running game. */ @@ -938,7 +945,7 @@ Phaser.Touch.prototype.constructor = Phaser.Touch; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Tween.js.html b/docs/Tween.js.html index ca2639dda..0b7981bb8 100644 --- a/docs/Tween.js.html +++ b/docs/Tween.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1352,7 +1360,7 @@ Phaser.Tween.prototype.constructor = Phaser.Tween; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/TweenManager.js.html b/docs/TweenManager.js.html index 7fd2091d0..4c4330823 100644 --- a/docs/TweenManager.js.html +++ b/docs/TweenManager.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,10 +551,6 @@ */ /** -* Phaser - TweenManager -* -* @class Phaser.TweenManager -* @classdesc * Phaser.Game has a single instance of the TweenManager through which all Tween objects are created and updated. * Tweens are hooked into the game clock and pause system, adjusting based on the game state. * @@ -554,8 +558,9 @@ * The difference being that tweens belong to a games instance of TweenManager, rather than to a global TWEEN object. * It also has callbacks swapped for Signals and a few issues patched with regard to properties and completion errors. * Please see https://github.com/sole/tween.js for a full list of contributors. +* +* @class Phaser.TweenManager * @constructor -* * @param {Phaser.Game} game - A reference to the currently running game. */ Phaser.TweenManager = function (game) { @@ -803,7 +808,7 @@ Phaser.TweenManager.prototype.constructor = Phaser.TweenManager; Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/Utils.js.html b/docs/Utils.js.html index 995084e3a..c5a8f9272 100644 --- a/docs/Utils.js.html +++ b/docs/Utils.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -1042,7 +1050,7 @@ if (!Array.prototype.forEach) * Source: http://www.html5gamedevs.com/topic/5988-phaser-12-ie9/ * Cameron Foale (http://www.kibibu.com) */ -if (typeof window.Uint32Array !== "function") +if (typeof window.Uint32Array !== "function" && typeof window.Uint32Array !== "object") { var CheapArray = function(type) { @@ -1111,7 +1119,7 @@ if (!window.console) Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:44 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/World.js.html b/docs/World.js.html index 4caa94e1a..abb1b3635 100644 --- a/docs/World.js.html +++ b/docs/World.js.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -547,8 +555,10 @@ p2.Body.prototype.parent = null; p2.Spring.prototype.parent = null; /** +* This is your main access to the P2 Physics World. +* From here you can create materials, listen for events and add bodies into the physics simulation. +* * @class Phaser.Physics.P2 -* @classdesc Physics World Constructor * @constructor * @param {Phaser.Game} game - Reference to the current game instance. * @param {object} [config] - Physics configuration object passed in from the game constructor. @@ -2442,7 +2452,7 @@ Object.defineProperty(Phaser.Physics.P2.prototype, "total", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/World.js_.html b/docs/World.js_.html index d660547ce..3ef4369eb 100644 --- a/docs/World.js_.html +++ b/docs/World.js_.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -543,12 +551,11 @@ */ /** -* Arcade Physics constructor. +* The Arcade Physics world. Contains Arcade Physics related collision, overlap and motion methods. * * @class Phaser.Physics.Arcade -* @classdesc Arcade Physics Constructor * @constructor -* @param {Phaser.Game} game reference to the current game instance. +* @param {Phaser.Game} game - reference to the current game instance. */ Phaser.Physics.Arcade = function (game) { @@ -943,8 +950,8 @@ Phaser.Physics.Arcade.prototype = { * NOTE: This function is not recursive, and will not test against children of objects passed (i.e. Groups or Tilemaps within other Groups). * * @method Phaser.Physics.Arcade#collide - * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.Tilemap|array} object1 - The first object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.Tilemap. - * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.Tilemap|array} object2 - The second object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.Tilemap. + * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.TilemapLayer|array} object1 - The first object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.TilemapLayer. + * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.TilemapLayer|array} object2 - The second object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.TilemapLayer. * @param {function} [collideCallback=null] - An optional callback function that is called if the objects collide. The two objects will be passed to this function in the same order in which you specified them, unless you are colliding Group vs. Sprite, in which case Sprite will always be the first parameter. * @param {function} [processCallback=null] - A callback function that lets you perform additional checks against the two objects if they overlap. If this is set then collision will only happen if processCallback returns true. The two objects will be passed to this function in the same order in which you specified them. * @param {object} [callbackContext] - The context in which to run the callbacks. @@ -997,8 +1004,8 @@ Phaser.Physics.Arcade.prototype = { * * @method Phaser.Physics.Arcade#collideHandler * @private - * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.Tilemap} object1 - The first object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.Tilemap. - * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.Tilemap} object2 - The second object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.Tilemap. Can also be an array of objects to check. + * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.TilemapLayer} object1 - The first object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.TilemapLayer. + * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.TilemapLayer} object2 - The second object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.TilemapLayer. Can also be an array of objects to check. * @param {function} collideCallback - An optional callback function that is called if the objects collide. The two objects will be passed to this function in the same order in which you specified them. * @param {function} processCallback - A callback function that lets you perform additional checks against the two objects if they overlap. If this is set then collision will only happen if processCallback returns true. The two objects will be passed to this function in the same order in which you specified them. * @param {object} callbackContext - The context in which to run the callbacks. @@ -2360,7 +2367,7 @@ Phaser.Physics.Arcade.prototype = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/World.js__.html b/docs/World.js__.html index 2f005f8c1..50e9f44d0 100644 --- a/docs/World.js__.html +++ b/docs/World.js__.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -561,9 +569,8 @@ * Feel free to attempt any of the above and submit a Pull Request with your code! Be sure to include test cases proving they work. * * @class Phaser.Physics.Ninja -* @classdesc Ninja Physics Constructor * @constructor -* @param {Phaser.Game} game reference to the current game instance. +* @param {Phaser.Game} game - reference to the current game instance. */ Phaser.Physics.Ninja = function (game) { @@ -875,8 +882,8 @@ Phaser.Physics.Ninja.prototype = { * The collideCallback is an optional function that is only called if two sprites collide. If a processCallback has been set then it needs to return true for collideCallback to be called. * * @method Phaser.Physics.Ninja#collide - * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.Tilemap} object1 - The first object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.Tilemap. - * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.Tilemap|array} object2 - The second object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.Tilemap. + * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.TilemapLayer} object1 - The first object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.TilemapLayer. + * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.TilemapLayer|array} object2 - The second object or array of objects to check. Can be Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.TilemapLayer. * @param {function} [collideCallback=null] - An optional callback function that is called if the objects collide. The two objects will be passed to this function in the same order in which you specified them. * @param {function} [processCallback=null] - A callback function that lets you perform additional checks against the two objects if they overlap. If this is set then collision will only happen if processCallback returns true. The two objects will be passed to this function in the same order in which you specified them. * @param {object} [callbackContext] - The context in which to run the callbacks. @@ -912,8 +919,8 @@ Phaser.Physics.Ninja.prototype = { * * @method Phaser.Physics.Ninja#collideHandler * @private - * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.Tilemap} object1 - The first object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.Tilemap. - * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.Tilemap} object2 - The second object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.Tilemap. Can also be an array of objects to check. + * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.TilemapLayer} object1 - The first object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter, or Phaser.TilemapLayer. + * @param {Phaser.Sprite|Phaser.Group|Phaser.Particles.Emitter|Phaser.TilemapLayer} object2 - The second object to check. Can be an instance of Phaser.Sprite, Phaser.Group, Phaser.Particles.Emitter or Phaser.TilemapLayer. Can also be an array of objects to check. * @param {function} collideCallback - An optional callback function that is called if the objects collide. The two objects will be passed to this function in the same order in which you specified them. * @param {function} processCallback - A callback function that lets you perform additional checks against the two objects if they overlap. If this is set then collision will only happen if processCallback returns true. The two objects will be passed to this function in the same order in which you specified them. * @param {object} callbackContext - The context in which to run the callbacks. @@ -1166,7 +1173,7 @@ Phaser.Physics.Ninja.prototype = { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:17 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/World.js___.html b/docs/World.js___.html index 18356d93d..26732c6f9 100644 --- a/docs/World.js___.html +++ b/docs/World.js___.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -889,7 +897,7 @@ Object.defineProperty(Phaser.World.prototype, "randomY", { Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/classes.list.html b/docs/classes.list.html index 0271b7383..9465e6bf6 100644 --- a/docs/classes.list.html +++ b/docs/classes.list.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -627,6 +635,14 @@ +
    + AudioSprite +
    +
    + +
    + +
    BitmapData
    @@ -1027,6 +1043,14 @@ +
    + Arcade +
    +
    + +
    + +
    Emitter
    @@ -1251,14 +1275,6 @@ -
    - Point -
    -
    - -
    - -
    Pointer
    @@ -1585,7 +1601,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:46 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/global.html b/docs/global.html index a8d2609d4..1e83eda71 100644 --- a/docs/global.html +++ b/docs/global.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -852,6 +860,221 @@ Note that all properties are cloned, including the name, index and UUID.

    + + + + +
    +

    createCustomLayer(width, height, children) → {Phaser.FlexLayer}

    + + +
    +
    + + +
    +

    A custom layer is centered on the game and maintains its aspect ratio as it scales up and down.

    +
    + + + + + + + +
    Parameters:
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NameTypeArgumentDescription
    width + + +number + + + + + + + + + +

    Width of this layer in pixels.

    height + + +number + + + + + + + + + +

    Height of this layer in pixels.

    children + + +array + + + + + + <optional>
    + + + + + +

    An array of children that are used to populate the FlexLayer.

    + + + + +
    + + + + + + + + + + + + + + + + + + + +
    Source:
    +
    + + + + + + + +
    + + + + + + + + + + + +
    Returns:
    + + +
    +

    The Layer object.

    +
    + + + +
    +
    + Type +
    +
    + +Phaser.FlexLayer + + +
    +
    + + + + +
    @@ -959,7 +1182,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Source:
    @@ -1112,7 +1335,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Source:
    @@ -1265,7 +1488,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Source:
    @@ -1357,7 +1580,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Source:
    @@ -1495,7 +1718,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Source:
    @@ -1633,7 +1856,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Source:
    @@ -1774,7 +1997,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Source:
    @@ -1843,7 +2066,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Source:
    @@ -1912,7 +2135,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Source:
    @@ -2240,7 +2463,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Source:
    @@ -2455,7 +2678,7 @@ Note that all properties are cloned, including the name, index and UUID.

    Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:45 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/index.html b/docs/index.html index 2f294e799..a1e0788a8 100644 --- a/docs/index.html +++ b/docs/index.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -578,9 +586,9 @@
  • License
  • <a name="about"></a>

    -

    Phaser 2.1.0

    +

    Phaser 2.1.2

    Phaser is a fast, free and fun open source game framework for making desktop and mobile browser HTML5 games. It uses Pixi.js internally for fast 2D Canvas and WebGL rendering.

    -

    Version: 2.1.0 "Cairhien" - Released: 9th September 2014

    +

    Version: 2.1.2 "Whitebridge" - Released: 9th October 2014

    By Richard Davey, Photon Storm

    div

    <a name="whats-new"></a>

    -

    Welcome to Phaser and What's new in 2.1.0?

    -

    Phaser 2.1 is a significant update, bringing literally hundreds of features, fixes and updates to the core framework. It's the result of months of hard work from both the Phaser team and the wonderful community on github and the forums.

    -

    We jumped to 2.1 because there are some API breaking changes from the 2.0.x range, especially with regard to P2 physics. P2 itself has undergone lots of changes recently, streamlining the API, adding enhancements like rotational springs and squashing bugs. This update of Phaser brings us fully up to date with P2.

    -

    We've also seen a shift in client requirements for truly responsive games. And that has lead to the introduction of a new Phaser scale mode: RESIZE. Combined with powerful new ways of setting game dimensions, and advanced parent container support, you can now have your Phaser game resize the actual renderer to fill the browser (or parent) and adjust accordingly as they resize. A new state level resize function is called with every change, allowing you to easily re-position sprites that need to be locked into fixed locations, regardless of resolution. We'll be enhancing the reponsive features of Phaser over the coming versions, but the core ground-work is in place and useable today.

    -

    We also took the decision with 2.1 to remove Ninja Physics from the core build. We had hoped it would get more traction and support from contributors, but sadly that wasn't the case. In light of this it's no longer bundled into the main library, saving some space. You can however find a build of Phaser with it in the build\custom folder called phaser-ninja-physics.js.

    -

    We'll move back to point updates now, with 2.1.1 being the next - and will keep a close eye on github issues and the forum. If you want to contribute, be it code, examples or just ideas, please do so. Phaser was born from and thrives on its community, and we're always looking for new members.

    +

    Welcome to Phaser and What's new in 2.1.2?

    +

    Phaser 2.1.2 carries on with our latest round of new features, updates and fixes, demonstrating our commitment to continuously improving our framework and responding to feedback.

    +

    This release adds in a number of new features including Audio Sprite json format support, native loading of XML files, Sound fades, per character Text colours, further updates to BitmapData, the ability to use BitmapData with frames as Sprite textures, Group filter, search the Cache by URL and plenty of updates and bug fixes too - including the death of the pesky getPixel issue on Safari / iOS.

    +

    Internally we are using Phaser in ever larger client based projects. Thousands of lines of code spread across many States and classes, and we're paying close attention to how best to adapt the API to make life easier for those building apps of the size we are. If there are any features you would like to see then now is the time to suggest them, either by email, the forum or github.

    +

    We're also pleased to announce that we have 3 new premium plugins gearing up for launch. They are:

    +

    Phaser Box2D - Adds complete Box2D support directly into Phaser, with lots of help methods, over 50 examples and 5 demo games.

    +

    Phaser Path Manager - Create complex motion paths for Sprites with a lovely visual editor and this new plugin. No longer rely on tweens for motion :) Instead draw a path, with full branch support, path orientation, segment speeds, path events and more.

    +

    Advanced Particle System - The particles included with Phaser are flexible and can create attractive effects. But Advanced Particles is a complete replacement offering professional level particle effects for your games. From multiple render targets, to bitmap caching to all kinds of events, emitters and properties.

    +

    Each plugin will come in a range of versions to suit all budgets and there are more on the way. Please visit the launch page to sign-up for notification as soon as they're ready.

    Until then happy coding everyone! And we hope to see you on the forums.

    boogie

    div

    @@ -615,175 +626,56 @@

    div

    <a name="change-log"></a>

    Change Log

    -

    Version 2.1.0 - "Cairhien" - 9th September 2014

    +

    Version 2.1.2 - "Whitebridge" - October 9th 2014

    New Features

      -
    • Updated to p2.js 0.6.0 - this was an API breaking change, so please see the p2.js section of this change log specifically if you're using p2 in your game.
    • -
    • If you are using CocoonJS, please set your game render type to CANVAS and not WEBGL or AUTO. You should also disable any of the ScaleManager screen resizing or margin setting code. By default in this mode CocoonJS will now set 'screencanvas=true' which helps with performance significantly.
    • -
    • Ninja Physics is no longer included in the build files by default. Not enough people were using it, and not enough contributions were coming in to help polish it up, so we've saved the space and removed it. It's still available in the grunt build files if you require it, but we're deprecating it from the core library at this time. It will make a return in Phaser3 when we move to a modular class system.
    • -
    • ScaleManager has a new scaleMode called RESIZE which will tell Phaser to track the size of the parent container (either a dom element or the browser window if none given) and set the canvas size to match it. If the parent changes size the canvas will resize as well, keeping a 1:1 pixel ratio. There is also a new ScaleManager.setResizeCallback method which will let you define your own function to handle resize events from the game, such as re-positioning sprites for a fluid responsive layout (#642)
    • -
    • The width and height given to the Phaser.Game constructor can now be numbers or strings in which case the value is treated as a percentage. For example a value of "100%" for the width and height will tell Phaser to size the game to match the parent container dimensions exactly (or the browser window if no parent is given). Equally a size of "50%" would tell it to be half the size of the parent. The values are retained even through resize events, allowing it to maintain a percentage size based on the parent even as it updates.
    • -
    • Device will now detect for Kindle and PS Vita (thanks @lucbloom)
    • -
    • Device will now detect for Cordova (thanks @videlais #1102)
    • -
    • Arcade Physics Body.skipQuadTree is a new boolean that if set to true when you collide the Sprite against a Group it will tell Phaser to skip using a QuadTree for that collision. This is handy if this Body is especially large.
    • -
    • Arcade Physics World.skipQuadTree will disable the use of all QuadTrees in collision methods, which can help performance in tightly packed scenes.
    • -
    • Cordova 'deviceready' event check added (thanks @videlais #1120)
    • -
    • Loader.useXDomainRequest boolean added. If true (the default is false, unless the browser is detected as being IE9 specifically) it will use XDomainRequest when loading JSON files instead of xhr. In rare IE edge-cases this may be required. You'll know if you need it (#1131 #1116)
    • -
    • Added support for Tiled objects type field (thanks @rex64 #1111)
    • -
    • Tile properties are now copied from the Tiled JSON data to the Phaser.Tile objects when parsed (thanks @beeglebug #1126)
    • -
    • All Images now have a frameData value, even if it's only one frame. This removes lots of engine code needed to check if images are sprite sheets or not, and simplifies game code too (thanks @lucbloom #1059)
    • -
    • Added a new Phaser.Rope object. This allows for a series of 'chained' Sprites and extends the Rope support built into Pixi. Access it via game.add.rope (thanks @codevinsky #1030)
    • -
    • Phaser.Device.isAndroidStockBrowser will inform you if your game is running in a stock Android browser (rather than Chrome) where you may wish to scale down effects, disable WebGL, etc (thanks @lucbloom #989)
    • -
    • Phaser.Camera has a new property position which is a Point object that allows you to get or set the camera position without having to read both the x and y values (thanks @Zielak #1015)
    • -
    • TileSprite now has the alive property, which should help with some Group operations (thanks @jonkelling #1085)
    • -
    • Events.onDestroy is a new signal that is dispatched whenever the parent is being destroyed. It's dispatched at the start of the destroy process, allowing you to perform any additional house cleaning needed (thanks @jonkelling #1084)
    • -
    • Group.onDestroy is a new signal that is dispatched whenever the Group is being destroyed. It's dispatched at the start of the destroy process, allowing you to perform any additional house cleaning needed (thanks @jonkelling #1084)
    • -
    • ScaleManager.destroy now removes the window and document event listeners, which are no longer created anonymously (thanks @eguneys #1092)
    • -
    • Input.Gamepad.destroy now destroys all connected SinglePads and clears event listeners.
    • -
    • SinglePad.destroy now clears all associated GamepadButton objects and signals.
    • -
    • Device.node and Device.nodeWebKit are two new properties (thanks @videlais #1129)
    • -
    • P2.PointProxy.mx and my values are get and set in meters with no pixel conversion taking place.
    • -
    • P2.InversePointProxy.mx and my values are get and set in meters with no pixel conversion taking place.
    • -
    • Pointer.dirty is a new boolean that is set by the InputHandler. It tells the Pointer to re-check all interactive objects it may be over on the next update, regardless if it has moved position or not. This helps solve issues where you may have a Button that on click generates a pop-up window that now obscures the Button (thanks @jflowers45 #882)
    • -
    • SoundManager.destroy is a new method that will destroy all current sounds and reset any callbacks.
    • -
    • StateManager.clearCurrentState now handles the process of clearing down the current state and is now called if the Game is destroyed.
    • -
    • Game.destroy now clears the current state, activating its shutdown callback if it had one. It also now destroys the SoundManager, stopping any currently running sounds (#1092)
    • -
    • Animation.onUpdate is a new event that is dispatched each time the animation frame changes. Due to its intensive nature it is disabled by default. Enable it with Animation.enableUpdate = true (#902)
    • -
    • Device now has new features to support detection of running inside a CocoonJS.App (thanks @videlais #1150)
    • -
    • Support for CocoonJS.App's 'onSuspended' and 'onActivated' events, making it so that the timers and sounds are stopped/started and muted/unmuted when the user swaps an app from the background to the fore or the reverse (thanks @videlais #1152)
    • -
    • Canvas.removeFromDOM(canvas) will remove a canvas element from the DOM.
    • -
    • Game.destroy now removes the games canvas element from the DOM.
    • -
    • ScaleManager.setMinMax(minWidth, minHeight, maxWidth, maxHeight) is a handy function to allow you to set all the min/max dimensions in one call.
    • -
    • ArcadePhysics.collide and overlap can now accept 2 Arrays of objects to be used in the collision checks (thanks @ctmartinez1992 #1158)
    • -
    • RetroFont has a new property called frameData which contains the Frame objects for each of the letters in the font, which can be used by Sprites.
    • -
    • Phaser.Canvas.setImageRenderingCrisp now sets image-rendering: pixelated, perfect for pixel art, which is now supported in Chrome 38.
    • -
    • Phaser.Mouse will now add a listener to the window to detect mouseup events. This is used to detect if the player releases the mouse while outside of the game canvas. Previously Pointer objects incorrectly thought they were still pressed when you returned the mouse over the canvas (#1167)
    • -
    • Rectangle.centerOn(x,y) allows you to quickly center a Rectangle on the given coordinates.
    • -
    • Group.addMultiple allows you to pass an array of game objects and they'll all be added to the Group in turn.
    • -
    • The StateManager will now check if a State has a method called resize. If it does, and if the game is running in the RESIZE Scale Mode then this method will be called whenever the game resizes. It will be passed two parameters: width and height that will match the games new dimensions. Resizing can happen as a result of either the parent container changing shape, or the browser window resizing.
    • -
    • Rectangle.topRight returns a Point object that represents the top-right coordinate of the Rectangle.
    • -
    • The grunt script now builds a new version of Phaser without any physics (including Arcade Physics), Tilemaps or Particles. This build is called phaser-no-physics.js and works stand-alone. Please note that things like the GameObjectFactory aren't changed, so they will still try and create a Tilemap for example should you ask them to (thanks @eguneys #1172)
    • -
    • Camera.roundPx is a new boolean. If set to true it will call view.floor as part of its update loop, keeping its boundary to integer values. Set to false to disable this from happening (#1141)
    • -
    • Phaser.Easing.Default is a new property that is used when a specific type of ease isn't given. It defaults to Linear.None but can be overridden to anything (thanks @alvinsight)
    • +
    • StateManager.unlink will null all State-level Phaser properties, such as game, add, etc. Useful if you never need to return to the State again.
    • +
    • Cache.removeImage has a new parameter: removeFromPixi which is true by default. It will remove the image from the Pixi BaseTextureCache as well as from the Phaser Cache. Set to false if you don't want the Pixi cache touched.
    • +
    • Group.ignoreDestroy boolean will bail out early from any call to Group.destroy. Handy if you need to create a global Group that persists across States.
    • +
    • Loader can now natively load XML files via load.xml. Once the XML file has loaded it is parsed via either DOMParser or ActiveXObject and then added to the Cache, where it can be retrieved via cache.getXML(key).
    • +
    • Cache now has support for XML files stored in their own container. You can add them with cache.addXML (typically this is done from the Loader automatically for you) and get them with cache.getXML(key). There is also cache.checkXMLKey(key), cache.checkKeys and cache.removeXML(key).
    • +
    • Rectangle.aabb is a new method that will take an array of Points and return a Rectangle that matches the AABB (bounding area) of the Points (thanks @codevinsky #1199)
    • +
    • AudioSprite support is now built into the Loader and SoundManager. AudioSprites are like sprite sheets, only they consist of a selection of audio files and markers in a json configuration. You can find more details at https://github.com/tonistiigi/audiosprite (thanks @codevinsky #1205)
    • +
    • Point.parse will return a new Point object based on the x and y properties of the object given to Point.parse (thanks @codevinsky #1198)
    • +
    • Sound.fadeOut(duration) will fade the Sound to a volume of zero over the duration given. At the end of the fade the Sound will be stopped and Sound.onFadeComplete dispatched.
    • +
    • Sound.fadeIn(duration, loop) will start the Sound playing, or restart it if already playing, set its volume to zero and then increase the volume over the duration given until it reaches 1. At the end of the fade the Sound.onFadeComplete event is dispatched.
    • +
    • Text.addColor allows you to set specific colors within the Text. It works by taking a color value, which is a typical HTML string such as #ff0000 or rgb(255,0,0) and a position. The position value is the index of the character in the Text string to start applying this color to. Once set the color remains in use until either another color or the end of the string is encountered. For example if the Text was Photon Storm and you did Text.addColor('#ffff00', 6) it would color in the word Storm in yellow.
    • +
    • Text.clearColors resets any previously set colors from Text.addColor.
    • +
    • If you pass a tinted Sprite to BitmapData.draw or BitmapData.copy it will now draw the tinted version of the Sprite to the BitmapData and not the original texture.
    • +
    • BitmapData.shadow(color, blur, x, y) provides a quick way to set all the relevant shadow settings, which are then be used in future draw calls.
    • +
    • Cache.addBitmapData has a new parameter: frameData allowing you to pass a Phaser.FrameData object along with the BitmapData.
    • +
    • Cache.getFrameData has a new parameter: map which allows you to specify which cache to get the FrameData from, i.e. Phaser.Cache.IMAGE or Phaser.Cache.BITMAPDATA.
    • +
    • Sprite.loadTexture if given a BitmapData as the texture will now query the cache to see if it has any associated FrameData, and if so it will load that into the AnimationManager.
    • +
    • BitmapData.textureLine takes a Phaser.Line object and an image in the image cache. It then accurately draws the image as a repeating texture for the full length of the line.
    • +
    • AnimationManager.name will now return the name property of the currently playing animation, if any.
    • +
    • Group.filter takes a predicate function and passes child, index, and the entire child array to it. It then returns an ArrayList containing all children that the predicate returns true for (thanks @codevinsky #1187)
    • +
    • Cache.checkUrl allows you to check if a resource is in the cache based on an absolute URL (thanks @englercj #1221)
    • +
    • Cache.getUrl gets a resource from the cache based on the absolute URL it was loaded from (thanks @englercj #1221)
    • +
    • Sound.allowMultiple allows you to have multiple instances of a single Sound playing at once. This is only useful when running under Web Audio, and we recommend you implement a local pooling system to not flood the sound channels. But it allows for one Sound object to play overlapping times, useful for gun effects and similar (#1220)

    Updates

      -
    • TypeScript definition updates to help fix for the noimplicitany option (thanks @Waog #1088)
    • -
    • TypeScript definitions fixes and updates (thanks @clark-stevenson @englercj @saikobee and @rhmoller)
    • -
    • All of the Pixi geom classes have been removed from the build file as they aren't needed (the Phaser.Geom classes overwrite them), saving some space in the process.
    • -
    • Improved consistency of clone methods on geometry classes (thanks @beeglebug #1130)
    • -
    • Removed Cache.isSpriteSheet method as no longer required (see #1059)
    • -
    • Added Cache.getFrameCount to return the number of frames in a FrameData.
    • -
    • Input.setMoveCallback has been removed due to deprecation.
    • -
    • BitmapData.refreshBuffer has been removed and replaced with BitmapData.update.
    • -
    • BitmapData.drawSprite has been removed due to deprecation. Use BitmapData.draw instead.
    • -
    • Pointer.moveCallback has been removed due to deprecation.
    • -
    • SinglePad.addButton has been removed due to deprecation.
    • -
    • P2.Body.loadData has been removed due to deprecation.
    • -
    • P2.World.defaultFriction and defaultRestitution have been removed due to deprecation.
    • -
    • Canvas.create noCocoon parameter has been removed due to deprecation.
    • -
    • Color.getColorInfo, RGBtoHexstring, RGBtoWebstring and colorToHexstring has been removed due to deprecation.
    • -
    • P2.PointProxy.x and y values are now returned in pixels (previously they were returned in meters). See PointProxy.mx/my for meter values.
    • -
    • P2.InversePointProxy.x and y values are now returned in pixels (previously they were returned in meters). See PointProxy.mx/my for meter values.
    • -
    • Arcade.overlap and collide are now more consistent about allowing a Group vs. Group or Group vs. Array of Groups set (thanks @pyromanfo #877 #1147)
    • -
    • The Pointer move callbacks are now sent an extra parameter: fromClick allowing your callbacks to distinguish between the Pointer just moving, or moving as a result of being pressed down (thanks @iforce2d #1055)
    • -
    • GamePad and SinglePad onAxisCallback parameters have changed. You are now sent: this (a reference to the SinglePad that caused the callback), the axis index and the axis value in that order.
    • -
    • If Time.elapsed was > Time.timeCap it would reset the elapsed value to be 1 / 60. It's now set to Time.timeCap and Time.timeCap defaults to 1 / 60 * 1000 as it's a ms value (thanks @casensiom #899)
    • -
    • Tiled polylines are now imported into the map objects property as well as map collision (#1117)
    • -
    • Tile.setCollision now adjusts the tiles interesting faces list as well, this allows you to create one-way jump tiles without using custom callbacks on a specific tile basis (thanks @RafaelOliveira #886)
    • -
    • Stage.offset has been moved to ScaleManager.offset
    • -
    • Stage.bounds has been removed, you can access it via Stage.getBounds.
    • -
    • Stage.checkOffsetInterval has been moved to ScaleManager.trackParentInterval
    • -
    • ScaleManager.hasResized signal has been removed. Use ScaleManager.setResizeCallback instead.
    • -
    • The World bounds can now be set to any size, including smaller than the game dimensions. Before it was locked to a minimum size of the game canvas, but it can now be anything.
    • -
    • ScaleManager.orientationSprite has been removed because it never displayed correctly anyway (it would be distorted by the game scale), it will be bought back in a future version by way of a custom orientation state.
    • -
    • ArcadePhysics.overlap has been updated so that the Body.overlapX/Y properties are set to the amount the two bodies overlapped by. Previously they were zero and only populated during the separation phase, but now the data is available for just overlap checks as well. You can then use these values in your ovrelap callback as required - note that they are changed for every check, so a Sprite overlap tested against 10 other sprites will have the overlapX/Y values updated 10 times in a single collision pass, so you can only safely use the values in the callback (#641)
    • -
    • Cache.getImage now returns null if the requested image wasn't found.
    • -
    • BitmapData now returns a reference to itself from all of its drawing related methods, allowing for easy function chaining.
    • -
    • The default size of a BitmapData if no width/height is given has been changed from 100x100 to 256x256.
    • -
    • Phaser.Text.destroy will now destroy the base texture by default (#1162)
    • -
    • BitmapData.copyPixels is now called BitmapData.copyRect and the method signature has changed.
    • -
    • BitmapData.draw method signature has changed significantly.
    • -
    • Phaser.Canvas.getSmoothingEnabled will return true if the given context has image smoothing enabled, otherwise false.
    • -
    • Math.numberArrayStep is a new method that allows you to return an array of numbers from min to max including an optional step parameter (thanks @codevinsky #1170)
    • -
    • Removed redundant if check from StateManager.preUpdate (thanks @FedeOmoto #1173)
    • +
    • TypeScript definitions fixes and updates (thanks @clark-stevenson @englercj @benjamindulau)
    • +
    • Added the sourceRect and maskRect parameters back into BitmapData.alphaMask as they were accidentally removed in 2.1 (thanks seejay92)
    • +
    • jsdoc fixes (thanks @danxexe #1209)
    • +
    • AnimationParser is now using value instead of nodeValue when parsing atlas XML files, avoiding Chrome deprecation warnings (thanks @valtterip #1189)
    • +
    • Color.webToColor restored. Converts a CSS rgba color into a native color value.
    • +
    • Color.createColor now populates the color property of the returned object with the results of Phaser.Color.getColor.
    • +
    • Color.createColor now has a color32 property with the results of Phaser.Color.getColor32.
    • +
    • Color.hexToColor has been optimised to inline the regex and has moved the createColor call so it now populates the color object fully, not just setting the r,g,b properties.
    • +
    • Keyboard.PLUS and Keyboard.MINUS have been added to the list of key codes (thanks @VictorBjelkholm #1281)

    Bug Fixes

      -
    • Remove escaping backslashes from RetroFont text set documentation (thanks @jackrugile #1051)
    • -
    • Phaser.Loader was incorrectly getting the responseText from _xhr instead of _ajax on IE9 xDomainRequests (thanks @lardratboy #1050)
    • -
    • Phaser.Physics.P2.addPolygon now takes a nested array again (thanks @wayfu #1060)
    • -
    • Fix for previous PR #1028 where the P2.setBoundsToWorld call was overriding setBoundsToWorld in the P2 constructor (thanks @Dumtard #1028)
    • -
    • Fix for scale issues in CocoonJS using webgl renderer and screencanvas (thanks @txusinho #1064)
    • -
    • Resolves issue with pixel perfect click / over detection on Sprites that used trimmed image atlases for animations or frames > 0.
    • -
    • Group.swap() updates the Z index values properly (thanks @Blank101 #1090)
    • -
    • Device now recognises ChromeOS as a desktop (thanks @alvinsight @hilts-vaughan #1091)
    • -
    • Fixed Point.rotate bug (thanks @gamedolphin #1107)
    • -
    • InputHandler.checkBoundsRect was incorrectly assigning a property in Sprites fixed to the camera being dragged left (thanks @CraigBeswetherick #1093)
    • -
    • Swapped argument order of Rectangle.containsRect (thanks @beeglebug #1095 #1125)
    • -
    • The Game configuration object "renderer" property was being wrongly assigned to Game.renderer instead of renderType (thanks @FedeOmoto #1127)
    • -
    • Fixed Group.removeBetweens default endIndex (thanks @darfux #1142)
    • -
    • Debug.cameraInfo no longer crashes if the camera bounds are nulled (thanks @wayfu #1143)
    • -
    • Camera.setBoundsToWorld no longer crashes if the camera bounds are nulled (thanks @wayfu #1143)
    • -
    • Fixed the resolution uniform type in the SampleFilter (thanks @VictoryRice #1137)
    • -
    • Calling P2.Body.destroy or ArcadePhysics.Body.destroy wouldn't null the parent sprite body, causing it to error in the next update (thanks @jonathanhooker #1077)
    • -
    • BitmapFonts are now correctly added to the Cache._bitmapFont array and returned via Cache.getBitmapFont (thanks @prudolfs #1076)
    • -
    • InputHandler docs updated to avoid Pointer data-type confusion (#1097)
    • -
    • If you used a single Game configuration object and didn't specify the enableDebug property it would crash on Debug.preUpdate (thanks @luizbills #1053)
    • -
    • The P2.World.postBroadphaseHandler now checks if the returned pairs array is empty or not before processing it (thanks @wayfu #934)
    • -
    • Tilemap.hasTile now checks the Tile.index value and will return false if the index is -1 (i.e. a non-active tile) (thanks @elgansayer #859)
    • -
    • Sound.restart used to cause the Sound to double-up if it was already playing when called. Now correctly stops the sound before restarting it (thanks @wombatbuddy #1136)
    • -
    • GamePad axis detection now works again properly in Firefox (#1035)
    • -
    • GamepadButton.justPressed and justReleased now correctly report if the button has just been pressed or released (thanks @padpadpad #1019)
    • -
    • TilemapParser.getEmptyData now correct adds an empty bodies array into layers. This fixes an issue where p2 couldn't convert a csv map into collision tiles (thanks @sru #845)
    • -
    • CocoonJS doesn't support mouse wheel events so they've been moved into a conditional check (thanks @videlais #1151)
    • -
    • ScaleManager window.resize handler would constantly dispatch enterPortrait and enterLandscape events on window resizing, regardless if it actually entered that orientation or not.
    • -
    • Added Sound._muteVolume which stops Firefox and IE9 crashing if you try to unmute a sound that hasn't yet been muted, which can also happen as a result of a game visibility change (thanks @osmanzeki #1108 #1123)
    • -
    • P2.World.getSprings used to return an empty array, but now returns all the Springs in the world (#1134)
    • -
    • Tween.generateData would skip the end values in the data array. They are now included as the object in the final array element.
    • -
    • Rectangle.bottom setter swapped the order of the calculation (thanks @JakeCoxon #1165)
    • -
    • Phaser.Text wouldn't render the text to its local canvas if you passed the text on the constructor and didn't add it to the display list. If a string is given it now updates the local canvas on creation.
    • -
    • Signal.removeAll would ignore the context parameter and remove all bindings regardless (thanks @alect #1168)
    • -
    • P2.Body.addCapsule didn't use to pass the radius value through pxm, but now does so you have to specify it in pixels, not meters.
    • -
    • The Debug canvas is now cleared on State swap.
    • -
    -

    p2.js 0.6.0 Changes and New Features

    -
      -
    • DistanceConstraint signature changed to take the new localAnchors.
    • -
    • World.createDistanceConstraint signature changed to include new local anchors (thanks @rhmoller #1169)
    • -
    • RevoluteConstraint signature changed to include worldPivot.
    • -
    • P2.Body now uses the new Body.type value instead of Body.motionState, however as P2.Body already have a property called type we have left the motionState getter/setter in for now.
    • -
    • World.enableBodySleeping has been removed and replaced with World.sleepMode.
    • -
    • Phaser P2.Springs are now LinearSprings by default.
    • -
    • World.createRotationalSpring will now let you create rotational springs.
    • -
    -

    Breaking changes

    -
      -
    • Renamed property .motionState to .type in class Body.
    • -
    • Changed constructor of RevoluteConstraint. Now the local pivots are passed as options instead of direct arguments. See the constraints demo.
    • -
    • Removed World.prototype.toJSON and .fromJSON.
    • -
    • Removed properties .enableBodySleeping and .enableIslandSleeping from World instances. The enum .sleepMode can be used instead. See the sleep demo.
    • -
    • Converted Spring to a base class for the new LinearSpring and RotationalSpring classes. LinearSpring can be used as the old Spring.
    • -
    • Utils.ARRAY_TYPE can now be overridden by injecting a global called P2_ARRAY_TYPE. Support for GLMAT_ARRAY_TYPE has been removed.
    • -
    -

    Other changes

    -
      -
    • Added flag .enableFrictionReduction to Narrowphase.
    • -
    • Added RevoluteConstraint.prototype.setLimits.
    • -
    • Added PrismaticConstraint.prototype.setLimits.
    • -
    • LockConstraint, DistanceConstraint, and GearConstraint can now be constructed from current body transforms.
    • -
    • RevoluteConstraint can now be constructed from the current body transforms and a world point.
    • -
    • Material id can now be passed via constructor.
    • -
    • ContactMaterial instances now have a property .contactSkinSize.
    • -
    • Added method Body.prototype.getAABB.
    • -
    • Limits for DistanceConstraint. See the DistanceConstraint demo.
    • -
    • Added Body.prototype.overlaps.
    • -
    • Added class OverlapKeeper.
    • -
    • If substepping is used in World.prototype.step, the substeps are aborted if slower than real time.
    • -
    • Added Heightfield/Convex and Heightfield/Circle collision support.
    • -
    • Added property .overlapKeeper to World.
    • -
    • EventEmitter.prototype.has can now check if any listeners were added to a given topic.
    • -
    • Added Utils.defaults.
    • +
    • If Game Objects change their frame, such as with an animated Sprite, and the change goes from a previously trimmed frame to a non-trimmed (full size) one, then the previous trim values were still left active, causing it to glitch (thanks stupot)
    • +
    • If you called StateManager.start from within a states init method which also had a preload method it would fail to start the next State.
    • +
    • StateManager.boot would call start on a State twice if it was added to the game and started before the DOM load had completed. This didn't cause an error but was duplicating function calls needlessly.
    • +
    • Changing any of the Text properties such as font, lineSpacing and fontSize on a Text object that wasn't already on the display list would cause an updateTransform error. Parent is now checked first in all setters.
    • +
    • A Timer with a delay value that was a float and not an integer would not loop correctly. Timer delay values are now passed through Math.round to avoid this (thanks @osmanzeki #1196)
    • +
    • The Loader would incorrectly call fileComplete for legacy audio files instead of setting it as a callback, throwing up errors if the audio file failed to load (thanks @spayton #1212)
    • +
    • The Uint32Array check used in Utils was incorrectly replacing Uint32Array on Safari, causing errors like BitmapData.getPixel32 to fail and other related issues (fixes #1043 and #1197)
    • +
    • Camera.follow would break if the parent of the Sprite being followed was scaled in any way (thanks @englercj #1222)
    • +
    • Fixed the 4fv uniform in the Pixelate filter.

    For details about changes made in previous versions of Phaser see the full Change Log at https://github.com/photonstorm/phaser/blob/master/CHANGELOG.md

    div

    @@ -812,9 +704,9 @@

    <a name="cdnjs"></a>

    CDNJS

    Phaser is now available on CDNJS. You can include the following in your html:

    -

    http://cdnjs.cloudflare.com/ajax/libs/phaser/2.1.0/phaser.min.js

    +

    http://cdnjs.cloudflare.com/ajax/libs/phaser/2.1.2/phaser.min.js

    Or if you prefer you can leave the protocol off, so it works via http and https:

    -

    //cdnjs.cloudflare.com/ajax/libs/phaser/2.1.0/phaser.min.js

    +

    //cdnjs.cloudflare.com/ajax/libs/phaser/2.1.2/phaser.min.js

    div

    <a name="requirements"></a>

    Requirements

    @@ -967,7 +859,7 @@ Sprites also have full Input support: click them, touch them, drag them around, Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:46 GMT+0100 (BST) using the DocStrap template. diff --git a/docs/namespaces.list.html b/docs/namespaces.list.html index 7e74eef51..37957c984 100644 --- a/docs/namespaces.list.html +++ b/docs/namespaces.list.html @@ -58,6 +58,10 @@ ArrayList +
  • + AudioSprite +
  • +
  • BitmapData
  • @@ -258,6 +262,10 @@ Particles +
  • + Arcade +
  • +
  • Emitter
  • @@ -627,6 +635,14 @@ +
    + AudioSprite +
    +
    + +
    + +
    BitmapData
    @@ -1027,6 +1043,14 @@ +
    + Arcade +
    +
    + +
    + +
    Emitter
    @@ -1251,14 +1275,6 @@ -
    - Point -
    -
    - -
    - -
    Pointer
    @@ -1585,7 +1601,7 @@ Documentation generated by JSDoc 3.3.0-dev - on Tue Sep 09 2014 15:29:18 GMT+0100 (BST) using the DocStrap template. + on Thu Oct 09 2014 16:09:46 GMT+0100 (BST) using the DocStrap template. diff --git a/src/Phaser.js b/src/Phaser.js index 435af349f..4b860d3d7 100644 --- a/src/Phaser.js +++ b/src/Phaser.js @@ -10,7 +10,7 @@ */ var Phaser = Phaser || { - VERSION: '2.1.2-dev', + VERSION: '2.1.2', GAMES: [], AUTO: 0,