Rectangle#equals()

equals(b) → {boolean} Determines whether the two Rectangles are equal.This method compares the x, y, width and height properties of each Rectangle. Parameters Name Type Description b Phaser.Rectangle The second Rectangle object. Returns boolean - A value of true if the two Rectangles have exactly the same values for the x, y, width and height properties; otherwise false. Source code: geom/Rectangle.js (Line 297)

Rectangle#empty

empty : boolean Determines whether or not this Rectangle object is empty. A Rectangle object is empty if its width or height is less than or equal to 0.If set to true then all of the Rectangle properties are set to 0. Gets or sets the Rectangles empty state. Source code: geom/Rectangle.js (Line 736)

Rectangle#copyTo()

copyTo(source) → {object} Copies the x, y, width and height properties from this Rectangle to any given object. Parameters Name Type Description source any The object to copy to. Returns object - This object. Source code: geom/Rectangle.js (Line 199)

Rectangle#copyFrom()

copyFrom(source) → {Phaser.Rectangle} Copies the x, y, width and height properties from any given object to this Rectangle. Parameters Name Type Description source any The object to copy from. Returns Phaser.Rectangle - This Rectangle object. Source code: geom/Rectangle.js (Line 187)

Rectangle#containsRect()

containsRect(b) → {boolean} Determines whether the first Rectangle object is fully contained within the second Rectangle object.A Rectangle object is said to contain another if the second Rectangle object falls entirely within the boundaries of the first. Parameters Name Type Description b Phaser.Rectangle The second Rectangle object. Returns boolean - A value of true if the Rectangle object contains the specified point; otherwise false. Source code: geom/Rectangle.js (Line 284)

Rectangle#contains()

contains(x, y) → {boolean} Determines whether the specified coordinates are contained within the region defined by this Rectangle object. Parameters Name Type Description x number The x coordinate of the point to test. y number The y coordinate of the point to test. Returns boolean - A value of true if the Rectangle object contains the specified point; otherwise false. Source code: geom/Rectangle.js (Line 271)

Rectangle#clone()

clone(output) → {Phaser.Rectangle} Returns a new Rectangle object with the same values for the x, y, width, and height properties as the original Rectangle object. Parameters Name Type Argument Description output Phaser.Rectangle <optional> Optional Rectangle object. If given the values will be set into the object, otherwise a brand new Rectangle object will be created and returned. Returns Phaser.Rectangle - Source code: geom/Rectangle.js (Line 259)

Rectangle#centerY

centerY : number The y coordinate of the center of the Rectangle. Source code: geom/Rectangle.js (Line 628)

Rectangle#centerX

centerX : number The x coordinate of the center of the Rectangle. Source code: geom/Rectangle.js (Line 611)

Rectangle#centerOn()

centerOn(x, y) → {Phaser.Rectangle} Centers this Rectangle so that the center coordinates match the given x and y values. Parameters Name Type Description x number The x coordinate to place the center of the Rectangle at. y number The y coordinate to place the center of the Rectangle at. Returns Phaser.Rectangle - This Rectangle object Source code: geom/Rectangle.js (Line 122)