Graphics#setChildIndex()

setChildIndex(child, index) Changes the position of an existing child in the display object container Parameters Name Type Description child DisplayObject The child DisplayObject instance for which you want to change the index number index Number The resulting index number for the child display object Inherited From PIXI.DisplayObjectContainer#setChildIndex Source code: pixi/display/DisplayObjectContainer.js (Line 132)

AnimationParser.spriteSheet()

<static> spriteSheet(game, key, frameWidth, frameHeight, frameMax, margin, spacing) → {Phaser.FrameData} Parse a Sprite Sheet and extract the animation frame data from it. Parameters Name Type Argument Default Description game Phaser.Game A reference to the currently running game. key string | Image The Game.Cache asset key of the Sprite Sheet image or an actual HTML Image element. frameWidth number The fixed width of each frame of the animation. frameHeight number

Frame#setTrim()

setTrim(trimmed, actualWidth, actualHeight, destX, destY, destWidth, destHeight) If the frame was trimmed when added to the Texture Atlas this records the trim and source data. Parameters Name Type Description trimmed boolean If this frame was trimmed or not. actualWidth number The width of the frame before being trimmed. actualHeight number The height of the frame before being trimmed. destX number The destination X position of the trimmed frame for display. destY number The desti

Component.FixedToCamera#cameraOffset

cameraOffset : Phaser.Point The x/y coordinate offset applied to the top-left of the camera that this Game Object will be drawn at if fixedToCamera is true. The values are relative to the top-left of the camera view and in addition to any parent of the Game Object on the display list. Source code: gameobjects/components/FixedToCamera.js (Line 86)

BitmapData#getPixel()

getPixel(x, y, out) → {object} Get the color of a specific pixel in the context into a color object.If you have drawn anything to the BitmapData since it was created you must call BitmapData.update to refresh the array buffer,otherwise this may return out of date color values, or worse - throw a run-time error as it tries to access an array element that doesn't exist. Parameters Name Type Argument Description x number The x coordinate of the pixel to be set. Must lay within the dimension

Graphics#previousPosition

[readonly] previousPosition : Phaser.Point The position the Game Object was located in the previous frame. Inherited From Phaser.Component.Core#previousPosition Source code: gameobjects/components/Core.js (Line 225)

FrameData#getFrame()

getFrame(index) → {Phaser.Frame} Get a Frame by its numerical index. Parameters Name Type Description index number The index of the frame you want to get. Returns Phaser.Frame - The frame, if found. Source code: animation/FrameData.js (Line 53)

Math#sinCosGenerator()

sinCosGenerator(length, sinAmplitude, cosAmplitude, frequency) → {Object} Generate a sine and cosine table simultaneously and extremely quickly.The parameters allow you to specify the length, amplitude and frequency of the wave.This generator is fast enough to be used in real-time.Code based on research by Franky of scene.at Parameters Name Type Description length number The length of the wave sinAmplitude number The amplitude to apply to the sine table (default 1.0) if you need values b

Graphics#inputEnabled

inputEnabled : boolean By default a Game Object won't process any input events. By setting inputEnabled to true a Phaser.InputHandler is createdfor this Game Object and it will then start to process click / touch events and more. You can then access the Input Handler via this.input. Note that Input related events are dispatched from this.events, i.e.: events.onInputDown. If you set this property to false it will stop the Input Handler from processing any more input events. If you want to temp

Frame#Frame

new Frame(index, x, y, width, height, name) A Frame is a single frame of an animation and is part of a FrameData collection. Parameters Name Type Description index number The index of this Frame within the FrameData set it is being added to. x number X position of the frame within the texture image. y number Y position of the frame within the texture image. width number Width of the frame within the texture image. height number Height of the frame within the texture image. name st