mirror of
https://github.com/photonstorm/phaser
synced 2024-11-22 20:53:39 +00:00
Fix multiple types on Tilemaps
This commit is contained in:
parent
dca7996179
commit
9375bb0530
16 changed files with 76 additions and 76 deletions
|
@ -222,7 +222,7 @@ var BaseSoundManager = new Class({
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {string} key - Asset key for the sound.
|
* @param {string} key - Asset key for the sound.
|
||||||
* @param {SoundConfig|SoundMarker} [extra] - An optional additional object containing settings to be applied to the sound. It could be either config or marker object.
|
* @param {(SoundConfig|SoundMarker)} [extra] - An optional additional object containing settings to be applied to the sound. It could be either config or marker object.
|
||||||
*
|
*
|
||||||
* @return {boolean} Whether the sound started playing successfully.
|
* @return {boolean} Whether the sound started playing successfully.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -443,7 +443,7 @@ var Tile = new Class({
|
||||||
* @param {Phaser.Cameras.Scene2D.Camera} [camera] - The Camera to use to perform the check.
|
* @param {Phaser.Cameras.Scene2D.Camera} [camera] - The Camera to use to perform the check.
|
||||||
* @param {object} [output] - [description]
|
* @param {object} [output] - [description]
|
||||||
*
|
*
|
||||||
* @return {Phaser.Geom.Rectangle|object}
|
* @return {(Phaser.Geom.Rectangle|object)}
|
||||||
*/
|
*/
|
||||||
getBounds: function (camera, output)
|
getBounds: function (camera, output)
|
||||||
{
|
{
|
||||||
|
|
|
@ -300,7 +300,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#convertLayerToStatic
|
* @method Phaser.Tilemaps.Tilemap#convertLayerToStatic
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {string|integer|Phaser.Tilemaps.DynamicTilemapLayer} [layer] - The name of the layer from Tiled, the
|
* @param {(string|integer|Phaser.Tilemaps.DynamicTilemapLayer)} [layer] - The name of the layer from Tiled, the
|
||||||
* index of the layer in the map, or a DynamicTilemapLayer.
|
* index of the layer in the map, or a DynamicTilemapLayer.
|
||||||
*
|
*
|
||||||
* @return {?Phaser.Tilemaps.StaticTilemapLayer} Returns the new layer that was created, or null if it
|
* @return {?Phaser.Tilemaps.StaticTilemapLayer} Returns the new layer that was created, or null if it
|
||||||
|
@ -444,7 +444,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#createDynamicLayer
|
* @method Phaser.Tilemaps.Tilemap#createDynamicLayer
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|string} layerID - The layer array index value, or if a string is given, the
|
* @param {(integer|string)} layerID - The layer array index value, or if a string is given, the
|
||||||
* layer name from Tiled.
|
* layer name from Tiled.
|
||||||
* @param {Phaser.Tilemaps.Tileset} tileset - The tileset the new layer will use.
|
* @param {Phaser.Tilemaps.Tileset} tileset - The tileset the new layer will use.
|
||||||
* @param {number} x - The x position to place the layer in the world. If not specified, it will
|
* @param {number} x - The x position to place the layer in the world. If not specified, it will
|
||||||
|
@ -503,7 +503,7 @@ var Tilemap = new Class({
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {string} name - The name of the object layer (from Tiled) to create Sprites from.
|
* @param {string} name - The name of the object layer (from Tiled) to create Sprites from.
|
||||||
* @param {integer|string} id - Either the id (object), gid (tile object) or name (object or
|
* @param {(integer|string)} id - Either the id (object), gid (tile object) or name (object or
|
||||||
* tile object) from Tiled. Ids are unique in Tiled, but a gid is shared by all tile objects
|
* tile object) from Tiled. Ids are unique in Tiled, but a gid is shared by all tile objects
|
||||||
* with the same graphic. The same name can be used on multiple objects.
|
* with the same graphic. The same name can be used on multiple objects.
|
||||||
* @param {object} spriteConfig - The config object to pass into the Sprite creator (i.e.
|
* @param {object} spriteConfig - The config object to pass into the Sprite creator (i.e.
|
||||||
|
@ -593,8 +593,8 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#createFromTiles
|
* @method Phaser.Tilemaps.Tilemap#createFromTiles
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - The tile index, or array of indexes, to create Sprites from.
|
* @param {(integer|array)} indexes - The tile index, or array of indexes, to create Sprites from.
|
||||||
* @param {integer|array} replacements - The tile index, or array of indexes, to change a converted
|
* @param {(integer|array)} replacements - The tile index, or array of indexes, to change a converted
|
||||||
* tile to. Set to `null` to leave the tiles unchanged. If an array is given, it is assumed to be a
|
* tile to. Set to `null` to leave the tiles unchanged. If an array is given, it is assumed to be a
|
||||||
* one-to-one mapping with the indexes array.
|
* one-to-one mapping with the indexes array.
|
||||||
* @param {object} spriteConfig - The config object to pass into the Sprite creator (i.e.
|
* @param {object} spriteConfig - The config object to pass into the Sprite creator (i.e.
|
||||||
|
@ -628,7 +628,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#createStaticLayer
|
* @method Phaser.Tilemaps.Tilemap#createStaticLayer
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|string} layerID - The layer array index value, or if a string is given, the
|
* @param {(integer|string)} layerID - The layer array index value, or if a string is given, the
|
||||||
* layer name from Tiled.
|
* layer name from Tiled.
|
||||||
* @param {Phaser.Tilemaps.Tileset} tileset - The tileset the new layer will use.
|
* @param {Phaser.Tilemaps.Tileset} tileset - The tileset the new layer will use.
|
||||||
* @param {number} x - The x position to place the layer in the world. If not specified, it will
|
* @param {number} x - The x position to place the layer in the world. If not specified, it will
|
||||||
|
@ -735,7 +735,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#filterObjects
|
* @method Phaser.Tilemaps.Tilemap#filterObjects
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {Phaser.Tilemaps.ObjectLayer|string} [objectLayer] - The name of an object layer (from Tiled) or an
|
* @param {(Phaser.Tilemaps.ObjectLayer|string)} [objectLayer] - The name of an object layer (from Tiled) or an
|
||||||
* ObjectLayer instance.
|
* ObjectLayer instance.
|
||||||
* @param {TilemapFilterCallback} callback - The callback. Each object in the given area will be passed to
|
* @param {TilemapFilterCallback} callback - The callback. Each object in the given area will be passed to
|
||||||
* this callback as the first and only parameter.
|
* this callback as the first and only parameter.
|
||||||
|
@ -835,7 +835,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#findObject
|
* @method Phaser.Tilemaps.Tilemap#findObject
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {Phaser.Tilemaps.ObjectLayer|string} [objectLayer] - The name of an object layer (from Tiled) or an
|
* @param {(Phaser.Tilemaps.ObjectLayer|string)} [objectLayer] - The name of an object layer (from Tiled) or an
|
||||||
* ObjectLayer instance.
|
* ObjectLayer instance.
|
||||||
* @param {TilemapFindCallback} callback - The callback. Each object in the given area will be passed to
|
* @param {TilemapFindCallback} callback - The callback. Each object in the given area will be passed to
|
||||||
* this callback as the first and only parameter.
|
* this callback as the first and only parameter.
|
||||||
|
@ -983,7 +983,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#getLayer
|
* @method Phaser.Tilemaps.Tilemap#getLayer
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {string|integer|Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer} [layer] - The name of the
|
* @param {(string|integer|Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer)} [layer] - The name of the
|
||||||
* layer from Tiled, the index of the layer in the map, a DynamicTilemapLayer or a
|
* layer from Tiled, the index of the layer in the map, a DynamicTilemapLayer or a
|
||||||
* StaticTilemapLayer. If not given will default to the maps current layer index.
|
* StaticTilemapLayer. If not given will default to the maps current layer index.
|
||||||
*
|
*
|
||||||
|
@ -1021,7 +1021,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#getLayerIndex
|
* @method Phaser.Tilemaps.Tilemap#getLayerIndex
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {string|integer|Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer} [layer] - The name of the
|
* @param {(string|integer|Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer)} [layer] - The name of the
|
||||||
* layer from Tiled, the index of the layer in the map, a DynamicTilemapLayer or a
|
* layer from Tiled, the index of the layer in the map, a DynamicTilemapLayer or a
|
||||||
* StaticTilemapLayer. If not given will default to the map's current layer index.
|
* StaticTilemapLayer. If not given will default to the map's current layer index.
|
||||||
*
|
*
|
||||||
|
@ -1156,7 +1156,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#getTilesWithinShape
|
* @method Phaser.Tilemaps.Tilemap#getTilesWithinShape
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {Phaser.Geom.Circle|Phaser.Geom.Line|Phaser.Geom.Rectangle|Phaser.Geom.Triangle} shape - A shape in world (pixel) coordinates
|
* @param {(Phaser.Geom.Circle|Phaser.Geom.Line|Phaser.Geom.Rectangle|Phaser.Geom.Triangle)} shape - A shape in world (pixel) coordinates
|
||||||
* @param {object} [filteringOptions] - Optional filters to apply when getting the tiles.
|
* @param {object} [filteringOptions] - Optional filters to apply when getting the tiles.
|
||||||
* @param {boolean} [filteringOptions.isNotEmpty=false] - If true, only return tiles that don't have
|
* @param {boolean} [filteringOptions.isNotEmpty=false] - If true, only return tiles that don't have
|
||||||
* -1 for an index.
|
* -1 for an index.
|
||||||
|
@ -1308,7 +1308,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#putTileAt
|
* @method Phaser.Tilemaps.Tilemap#putTileAt
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {integer} tileX - [description]
|
* @param {integer} tileX - [description]
|
||||||
* @param {integer} tileY - [description]
|
* @param {integer} tileY - [description]
|
||||||
* @param {boolean} [recalculateFaces=true] - [description]
|
* @param {boolean} [recalculateFaces=true] - [description]
|
||||||
|
@ -1339,7 +1339,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#putTileAtWorldXY
|
* @method Phaser.Tilemaps.Tilemap#putTileAtWorldXY
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {integer} worldX - [description]
|
* @param {integer} worldX - [description]
|
||||||
* @param {integer} worldY - [description]
|
* @param {integer} worldY - [description]
|
||||||
* @param {boolean} [recalculateFaces=true] - [description]
|
* @param {boolean} [recalculateFaces=true] - [description]
|
||||||
|
@ -1372,7 +1372,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#putTilesAt
|
* @method Phaser.Tilemaps.Tilemap#putTilesAt
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer[]|integer[][]|Phaser.Tilemaps.Tile[]|Phaser.Tilemaps.Tile[][]} tile - A row (array) or grid (2D array) of Tiles
|
* @param {(integer[]|integer[][]|Phaser.Tilemaps.Tile[]|Phaser.Tilemaps.Tile[][])} tile - A row (array) or grid (2D array) of Tiles
|
||||||
* or tile indexes to place.
|
* or tile indexes to place.
|
||||||
* @param {integer} tileX - [description]
|
* @param {integer} tileX - [description]
|
||||||
* @param {integer} tileY - [description]
|
* @param {integer} tileY - [description]
|
||||||
|
@ -1523,7 +1523,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#removeTileAt
|
* @method Phaser.Tilemaps.Tilemap#removeTileAt
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {integer} tileX - [description]
|
* @param {integer} tileX - [description]
|
||||||
* @param {integer} tileY - [description]
|
* @param {integer} tileY - [description]
|
||||||
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
||||||
|
@ -1554,7 +1554,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#removeTileAtWorldXY
|
* @method Phaser.Tilemaps.Tilemap#removeTileAtWorldXY
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {number} worldX - [description]
|
* @param {number} worldX - [description]
|
||||||
* @param {number} worldY - [description]
|
* @param {number} worldY - [description]
|
||||||
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
||||||
|
@ -1655,7 +1655,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#setCollision
|
* @method Phaser.Tilemaps.Tilemap#setCollision
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - Either a single tile index, or an array of tile indexes.
|
* @param {(integer|array)} indexes - Either a single tile index, or an array of tile indexes.
|
||||||
* @param {boolean} [collides=true] - If true it will enable collision. If false it will clear
|
* @param {boolean} [collides=true] - If true it will enable collision. If false it will clear
|
||||||
* collision.
|
* collision.
|
||||||
* @param {boolean} [recalculateFaces=true] - Whether or not to recalculate the tile faces after the
|
* @param {boolean} [recalculateFaces=true] - Whether or not to recalculate the tile faces after the
|
||||||
|
@ -1813,7 +1813,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#setTileIndexCallback
|
* @method Phaser.Tilemaps.Tilemap#setTileIndexCallback
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - Either a single tile index, or an array of tile indexes to have a
|
* @param {(integer|array)} indexes - Either a single tile index, or an array of tile indexes to have a
|
||||||
* collision callback set for.
|
* collision callback set for.
|
||||||
* @param {function} callback - The callback that will be invoked when the tile is collided with.
|
* @param {function} callback - The callback that will be invoked when the tile is collided with.
|
||||||
* @param {object} callbackContext - The context under which the callback is called.
|
* @param {object} callbackContext - The context under which the callback is called.
|
||||||
|
@ -1869,7 +1869,7 @@ var Tilemap = new Class({
|
||||||
* @method Phaser.Tilemaps.Tilemap#setLayer
|
* @method Phaser.Tilemaps.Tilemap#setLayer
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {string|integer|Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer} [layer] - The name of the
|
* @param {(string|integer|Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer)} [layer] - The name of the
|
||||||
* layer from Tiled, the index of the layer in the map, a DynamicTilemapLayer or a
|
* layer from Tiled, the index of the layer in the map, a DynamicTilemapLayer or a
|
||||||
* StaticTilemapLayer. If not given will default to the map's current layer index.
|
* StaticTilemapLayer. If not given will default to the map's current layer index.
|
||||||
*
|
*
|
||||||
|
@ -1943,7 +1943,7 @@ var Tilemap = new Class({
|
||||||
*
|
*
|
||||||
* @param {integer} tileWidth - The width of the tiles (in pixels) in the layer.
|
* @param {integer} tileWidth - The width of the tiles (in pixels) in the layer.
|
||||||
* @param {integer} tileHeight - The height of the tiles (in pixels) in the layer.
|
* @param {integer} tileHeight - The height of the tiles (in pixels) in the layer.
|
||||||
* @param {string|integer|Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer} [layer] - The name of the
|
* @param {(string|integer|Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer)} [layer] - The name of the
|
||||||
* layer from Tiled, the index of the layer in the map, a DynamicTilemapLayer or a
|
* layer from Tiled, the index of the layer in the map, a DynamicTilemapLayer or a
|
||||||
* StaticTilemapLayer. If not given will default to the map's current layer index.
|
* StaticTilemapLayer. If not given will default to the map's current layer index.
|
||||||
*
|
*
|
||||||
|
|
|
@ -18,8 +18,8 @@ var ReplaceByIndex = require('./ReplaceByIndex');
|
||||||
* @function Phaser.Tilemaps.Components.CreateFromTiles
|
* @function Phaser.Tilemaps.Components.CreateFromTiles
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - The tile index, or array of indexes, to create Sprites from.
|
* @param {(integer|array)} indexes - The tile index, or array of indexes, to create Sprites from.
|
||||||
* @param {integer|array} replacements - The tile index, or array of indexes, to change a converted
|
* @param {(integer|array)} replacements - The tile index, or array of indexes, to change a converted
|
||||||
* tile to. Set to `null` to leave the tiles unchanged. If an array is given, it is assumed to be a
|
* tile to. Set to `null` to leave the tiles unchanged. If an array is given, it is assumed to be a
|
||||||
* one-to-one mapping with the indexes array.
|
* one-to-one mapping with the indexes array.
|
||||||
* @param {object} spriteConfig - The config object to pass into the Sprite creator (i.e.
|
* @param {object} spriteConfig - The config object to pass into the Sprite creator (i.e.
|
||||||
|
@ -27,7 +27,7 @@ var ReplaceByIndex = require('./ReplaceByIndex');
|
||||||
* @param {Phaser.Scene} [scene=scene the map is within] - The Scene to create the Sprites within.
|
* @param {Phaser.Scene} [scene=scene the map is within] - The Scene to create the Sprites within.
|
||||||
* @param {Phaser.Cameras.Scene2D.Camera} [camera=main camera] - The Camera to use when determining the world XY
|
* @param {Phaser.Cameras.Scene2D.Camera} [camera=main camera] - The Camera to use when determining the world XY
|
||||||
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
||||||
*
|
*
|
||||||
* @return {Phaser.GameObjects.Sprite[]} An array of the Sprites that were created.
|
* @return {Phaser.GameObjects.Sprite[]} An array of the Sprites that were created.
|
||||||
*/
|
*/
|
||||||
var CreateFromTiles = function (indexes, replacements, spriteConfig, scene, camera, layer)
|
var CreateFromTiles = function (indexes, replacements, spriteConfig, scene, camera, layer)
|
||||||
|
|
|
@ -28,7 +28,7 @@ var TriangleToRectangle = function (triangle, rect)
|
||||||
* @function Phaser.Tilemaps.Components.GetTilesWithinShape
|
* @function Phaser.Tilemaps.Components.GetTilesWithinShape
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {Phaser.Geom.Circle|Phaser.Geom.Line|Phaser.Geom.Rectangle|Phaser.Geom.Triangle} shape - A shape in world (pixel) coordinates
|
* @param {(Phaser.Geom.Circle|Phaser.Geom.Line|Phaser.Geom.Rectangle|Phaser.Geom.Triangle)} shape - A shape in world (pixel) coordinates
|
||||||
* @param {object} [filteringOptions] - Optional filters to apply when getting the tiles.
|
* @param {object} [filteringOptions] - Optional filters to apply when getting the tiles.
|
||||||
* @param {boolean} [filteringOptions.isNotEmpty=false] - If true, only return tiles that don't have
|
* @param {boolean} [filteringOptions.isNotEmpty=false] - If true, only return tiles that don't have
|
||||||
* -1 for an index.
|
* -1 for an index.
|
||||||
|
@ -38,7 +38,7 @@ var TriangleToRectangle = function (triangle, rect)
|
||||||
* have at least one interesting face.
|
* have at least one interesting face.
|
||||||
* @param {Phaser.Cameras.Scene2D.Camera} [camera=main camera] - [description]
|
* @param {Phaser.Cameras.Scene2D.Camera} [camera=main camera] - [description]
|
||||||
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
||||||
*
|
*
|
||||||
* @return {Phaser.Tilemaps.Tile[]} Array of Tile objects.
|
* @return {Phaser.Tilemaps.Tile[]} Array of Tile objects.
|
||||||
*/
|
*/
|
||||||
var GetTilesWithinShape = function (shape, filteringOptions, camera, layer)
|
var GetTilesWithinShape = function (shape, filteringOptions, camera, layer)
|
||||||
|
|
|
@ -18,12 +18,12 @@ var SetTileCollision = require('./SetTileCollision');
|
||||||
* @function Phaser.Tilemaps.Components.PutTileAt
|
* @function Phaser.Tilemaps.Components.PutTileAt
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {integer} tileX - [description]
|
* @param {integer} tileX - [description]
|
||||||
* @param {integer} tileY - [description]
|
* @param {integer} tileY - [description]
|
||||||
* @param {boolean} [recalculateFaces=true] - [description]
|
* @param {boolean} [recalculateFaces=true] - [description]
|
||||||
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
||||||
*
|
*
|
||||||
* @return {Phaser.Tilemaps.Tile} The Tile object that was created or added to this map.
|
* @return {Phaser.Tilemaps.Tile} The Tile object that was created or added to this map.
|
||||||
*/
|
*/
|
||||||
var PutTileAt = function (tile, tileX, tileY, recalculateFaces, layer)
|
var PutTileAt = function (tile, tileX, tileY, recalculateFaces, layer)
|
||||||
|
|
|
@ -17,13 +17,13 @@ var WorldToTileY = require('./WorldToTileY');
|
||||||
* @function Phaser.Tilemaps.Components.PutTileAtWorldXY
|
* @function Phaser.Tilemaps.Components.PutTileAtWorldXY
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {integer} worldX - [description]
|
* @param {integer} worldX - [description]
|
||||||
* @param {integer} worldY - [description]
|
* @param {integer} worldY - [description]
|
||||||
* @param {boolean} [recalculateFaces=true] - [description]
|
* @param {boolean} [recalculateFaces=true] - [description]
|
||||||
* @param {Phaser.Cameras.Scene2D.Camera} [camera=main camera] - [description]
|
* @param {Phaser.Cameras.Scene2D.Camera} [camera=main camera] - [description]
|
||||||
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
||||||
*
|
*
|
||||||
* @return {Phaser.Tilemaps.Tile} The Tile object that was created or added to this map.
|
* @return {Phaser.Tilemaps.Tile} The Tile object that was created or added to this map.
|
||||||
*/
|
*/
|
||||||
var PutTileAtWorldXY = function (tile, worldX, worldY, recalculateFaces, camera, layer)
|
var PutTileAtWorldXY = function (tile, worldX, worldY, recalculateFaces, camera, layer)
|
||||||
|
|
|
@ -17,7 +17,7 @@ var PutTileAt = require('./PutTileAt');
|
||||||
* @function Phaser.Tilemaps.Components.PutTilesAt
|
* @function Phaser.Tilemaps.Components.PutTilesAt
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer[]|integer[][]|Phaser.Tilemaps.Tile[]|Phaser.Tilemaps.Tile[][]} tile - A row (array) or grid (2D array) of Tiles
|
* @param {(integer[]|integer[][]|Phaser.Tilemaps.Tile[]|Phaser.Tilemaps.Tile[][])} tile - A row (array) or grid (2D array) of Tiles
|
||||||
* or tile indexes to place.
|
* or tile indexes to place.
|
||||||
* @param {integer} tileX - [description]
|
* @param {integer} tileX - [description]
|
||||||
* @param {integer} tileY - [description]
|
* @param {integer} tileY - [description]
|
||||||
|
|
|
@ -15,14 +15,14 @@ var CalculateFacesAt = require('./CalculateFacesAt');
|
||||||
* @function Phaser.Tilemaps.Components.RemoveTileAt
|
* @function Phaser.Tilemaps.Components.RemoveTileAt
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {integer} tileX - [description]
|
* @param {integer} tileX - [description]
|
||||||
* @param {integer} tileY - [description]
|
* @param {integer} tileY - [description]
|
||||||
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
||||||
* location with null instead of a Tile with an index of -1.
|
* location with null instead of a Tile with an index of -1.
|
||||||
* @param {boolean} [recalculateFaces=true] - [description]
|
* @param {boolean} [recalculateFaces=true] - [description]
|
||||||
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
||||||
*
|
*
|
||||||
* @return {Phaser.Tilemaps.Tile} The Tile object that was removed.
|
* @return {Phaser.Tilemaps.Tile} The Tile object that was removed.
|
||||||
*/
|
*/
|
||||||
var RemoveTileAt = function (tileX, tileY, replaceWithNull, recalculateFaces, layer)
|
var RemoveTileAt = function (tileX, tileY, replaceWithNull, recalculateFaces, layer)
|
||||||
|
|
|
@ -15,7 +15,7 @@ var WorldToTileY = require('./WorldToTileY');
|
||||||
* @function Phaser.Tilemaps.Components.RemoveTileAtWorldXY
|
* @function Phaser.Tilemaps.Components.RemoveTileAtWorldXY
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {number} worldX - [description]
|
* @param {number} worldX - [description]
|
||||||
* @param {number} worldY - [description]
|
* @param {number} worldY - [description]
|
||||||
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
||||||
|
@ -23,7 +23,7 @@ var WorldToTileY = require('./WorldToTileY');
|
||||||
* @param {boolean} [recalculateFaces=true] - [description]
|
* @param {boolean} [recalculateFaces=true] - [description]
|
||||||
* @param {Phaser.Cameras.Scene2D.Camera} [camera=main camera] - [description]
|
* @param {Phaser.Cameras.Scene2D.Camera} [camera=main camera] - [description]
|
||||||
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
* @param {Phaser.Tilemaps.LayerData} layer - The Tilemap Layer to act upon.
|
||||||
*
|
*
|
||||||
* @return {Phaser.Tilemaps.Tile} The Tile object that was removed.
|
* @return {Phaser.Tilemaps.Tile} The Tile object that was removed.
|
||||||
*/
|
*/
|
||||||
var RemoveTileAtWorldXY = function (worldX, worldY, replaceWithNull, recalculateFaces, camera, layer)
|
var RemoveTileAtWorldXY = function (worldX, worldY, replaceWithNull, recalculateFaces, camera, layer)
|
||||||
|
|
|
@ -16,7 +16,7 @@ var SetLayerCollisionIndex = require('./SetLayerCollisionIndex');
|
||||||
* @function Phaser.Tilemaps.Components.SetCollision
|
* @function Phaser.Tilemaps.Components.SetCollision
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - Either a single tile index, or an array of tile indexes.
|
* @param {(integer|array)} indexes - Either a single tile index, or an array of tile indexes.
|
||||||
* @param {boolean} [collides=true] - If true it will enable collision. If false it will clear
|
* @param {boolean} [collides=true] - If true it will enable collision. If false it will clear
|
||||||
* collision.
|
* collision.
|
||||||
* @param {boolean} [recalculateFaces=true] - Whether or not to recalculate the tile faces after the
|
* @param {boolean} [recalculateFaces=true] - Whether or not to recalculate the tile faces after the
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
* @function Phaser.Tilemaps.Components.SetTileIndexCallback
|
* @function Phaser.Tilemaps.Components.SetTileIndexCallback
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - Either a single tile index, or an array of tile indexes to have a
|
* @param {(integer|array)} indexes - Either a single tile index, or an array of tile indexes to have a
|
||||||
* collision callback set for.
|
* collision callback set for.
|
||||||
* @param {function} callback - The callback that will be invoked when the tile is collided with.
|
* @param {function} callback - The callback that will be invoked when the tile is collided with.
|
||||||
* @param {object} callbackContext - The context under which the callback is called.
|
* @param {object} callbackContext - The context under which the callback is called.
|
||||||
|
|
|
@ -190,8 +190,8 @@ var DynamicTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.DynamicTilemapLayer#createFromTiles
|
* @method Phaser.Tilemaps.DynamicTilemapLayer#createFromTiles
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - The tile index, or array of indexes, to create Sprites from.
|
* @param {(integer|array)} indexes - The tile index, or array of indexes, to create Sprites from.
|
||||||
* @param {integer|array} replacements - The tile index, or array of indexes, to change a converted
|
* @param {(integer|array)} replacements - The tile index, or array of indexes, to change a converted
|
||||||
* tile to. Set to `null` to leave the tiles unchanged. If an array is given, it is assumed to be a
|
* tile to. Set to `null` to leave the tiles unchanged. If an array is given, it is assumed to be a
|
||||||
* one-to-one mapping with the indexes array.
|
* one-to-one mapping with the indexes array.
|
||||||
* @param {object} spriteConfig - The config object to pass into the Sprite creator (i.e.
|
* @param {object} spriteConfig - The config object to pass into the Sprite creator (i.e.
|
||||||
|
@ -478,7 +478,7 @@ var DynamicTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.DynamicTilemapLayer#getTilesWithinShape
|
* @method Phaser.Tilemaps.DynamicTilemapLayer#getTilesWithinShape
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {Phaser.Geom.Circle|Phaser.Geom.Line|Phaser.Geom.Rectangle|Phaser.Geom.Triangle} shape - A shape in world (pixel) coordinates
|
* @param {(Phaser.Geom.Circle|Phaser.Geom.Line|Phaser.Geom.Rectangle|Phaser.Geom.Triangle)} shape - A shape in world (pixel) coordinates
|
||||||
* @param {object} [filteringOptions] - Optional filters to apply when getting the tiles.
|
* @param {object} [filteringOptions] - Optional filters to apply when getting the tiles.
|
||||||
* @param {boolean} [filteringOptions.isNotEmpty=false] - If true, only return tiles that don't have
|
* @param {boolean} [filteringOptions.isNotEmpty=false] - If true, only return tiles that don't have
|
||||||
* -1 for an index.
|
* -1 for an index.
|
||||||
|
@ -565,7 +565,7 @@ var DynamicTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.DynamicTilemapLayer#putTileAt
|
* @method Phaser.Tilemaps.DynamicTilemapLayer#putTileAt
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {integer} tileX - [description]
|
* @param {integer} tileX - [description]
|
||||||
* @param {integer} tileY - [description]
|
* @param {integer} tileY - [description]
|
||||||
* @param {boolean} [recalculateFaces=true] - [description]
|
* @param {boolean} [recalculateFaces=true] - [description]
|
||||||
|
@ -586,7 +586,7 @@ var DynamicTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.DynamicTilemapLayer#putTileAtWorldXY
|
* @method Phaser.Tilemaps.DynamicTilemapLayer#putTileAtWorldXY
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {integer} worldX - [description]
|
* @param {integer} worldX - [description]
|
||||||
* @param {integer} worldY - [description]
|
* @param {integer} worldY - [description]
|
||||||
* @param {boolean} [recalculateFaces=true] - [description]
|
* @param {boolean} [recalculateFaces=true] - [description]
|
||||||
|
@ -609,7 +609,7 @@ var DynamicTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.DynamicTilemapLayer#putTilesAt
|
* @method Phaser.Tilemaps.DynamicTilemapLayer#putTilesAt
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer[]|integer[][]|Phaser.Tilemaps.Tile[]|Phaser.Tilemaps.Tile[][]} tile - A row (array) or grid (2D array) of Tiles
|
* @param {(integer[]|integer[][]|Phaser.Tilemaps.Tile[]|Phaser.Tilemaps.Tile[][])} tile - A row (array) or grid (2D array) of Tiles
|
||||||
* or tile indexes to place.
|
* or tile indexes to place.
|
||||||
* @param {integer} tileX - [description]
|
* @param {integer} tileX - [description]
|
||||||
* @param {integer} tileY - [description]
|
* @param {integer} tileY - [description]
|
||||||
|
@ -656,7 +656,7 @@ var DynamicTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.DynamicTilemapLayer#removeTileAt
|
* @method Phaser.Tilemaps.DynamicTilemapLayer#removeTileAt
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {integer} tileX - [description]
|
* @param {integer} tileX - [description]
|
||||||
* @param {integer} tileY - [description]
|
* @param {integer} tileY - [description]
|
||||||
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
||||||
|
@ -677,7 +677,7 @@ var DynamicTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.DynamicTilemapLayer#removeTileAtWorldXY
|
* @method Phaser.Tilemaps.DynamicTilemapLayer#removeTileAtWorldXY
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|Phaser.Tilemaps.Tile} tile - The index of this tile to set or a Tile object.
|
* @param {(integer|Phaser.Tilemaps.Tile)} tile - The index of this tile to set or a Tile object.
|
||||||
* @param {number} worldX - [description]
|
* @param {number} worldX - [description]
|
||||||
* @param {number} worldY - [description]
|
* @param {number} worldY - [description]
|
||||||
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
* @param {boolean} [replaceWithNull=true] - If true, this will replace the tile at the specified
|
||||||
|
@ -751,7 +751,7 @@ var DynamicTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.DynamicTilemapLayer#setCollision
|
* @method Phaser.Tilemaps.DynamicTilemapLayer#setCollision
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - Either a single tile index, or an array of tile indexes.
|
* @param {(integer|array)} indexes - Either a single tile index, or an array of tile indexes.
|
||||||
* @param {boolean} [collides=true] - If true it will enable collision. If false it will clear
|
* @param {boolean} [collides=true] - If true it will enable collision. If false it will clear
|
||||||
* collision.
|
* collision.
|
||||||
* @param {boolean} [recalculateFaces=true] - Whether or not to recalculate the tile faces after the
|
* @param {boolean} [recalculateFaces=true] - Whether or not to recalculate the tile faces after the
|
||||||
|
@ -874,7 +874,7 @@ var DynamicTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.DynamicTilemapLayer#setTileIndexCallback
|
* @method Phaser.Tilemaps.DynamicTilemapLayer#setTileIndexCallback
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - Either a single tile index, or an array of tile indexes to have a
|
* @param {(integer|array)} indexes - Either a single tile index, or an array of tile indexes to have a
|
||||||
* collision callback set for.
|
* collision callback set for.
|
||||||
* @param {function} callback - The callback that will be invoked when the tile is collided with.
|
* @param {function} callback - The callback that will be invoked when the tile is collided with.
|
||||||
* @param {object} callbackContext - The context under which the callback is called.
|
* @param {object} callbackContext - The context under which the callback is called.
|
||||||
|
|
|
@ -30,7 +30,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#name
|
* @name Phaser.Tilemaps.LayerData#name
|
||||||
* @type {string}
|
* @type {string}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -39,7 +39,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#x
|
* @name Phaser.Tilemaps.LayerData#x
|
||||||
* @type {number}
|
* @type {number}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -48,7 +48,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#y
|
* @name Phaser.Tilemaps.LayerData#y
|
||||||
* @type {number}
|
* @type {number}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -57,7 +57,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#width
|
* @name Phaser.Tilemaps.LayerData#width
|
||||||
* @type {number}
|
* @type {number}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -66,7 +66,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#height
|
* @name Phaser.Tilemaps.LayerData#height
|
||||||
* @type {number}
|
* @type {number}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -75,7 +75,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#tileWidth
|
* @name Phaser.Tilemaps.LayerData#tileWidth
|
||||||
* @type {number}
|
* @type {number}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -84,7 +84,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#tileHeight
|
* @name Phaser.Tilemaps.LayerData#tileHeight
|
||||||
* @type {number}
|
* @type {number}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -93,7 +93,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#baseTileWidth
|
* @name Phaser.Tilemaps.LayerData#baseTileWidth
|
||||||
* @type {number}
|
* @type {number}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -102,7 +102,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#baseTileHeight
|
* @name Phaser.Tilemaps.LayerData#baseTileHeight
|
||||||
* @type {number}
|
* @type {number}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -111,7 +111,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#widthInPixels
|
* @name Phaser.Tilemaps.LayerData#widthInPixels
|
||||||
* @type {number}
|
* @type {number}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -120,7 +120,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#heightInPixels
|
* @name Phaser.Tilemaps.LayerData#heightInPixels
|
||||||
* @type {number}
|
* @type {number}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -129,7 +129,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#alpha
|
* @name Phaser.Tilemaps.LayerData#alpha
|
||||||
* @type {float}
|
* @type {float}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -138,7 +138,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#visible
|
* @name Phaser.Tilemaps.LayerData#visible
|
||||||
* @type {boolean}
|
* @type {boolean}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -147,7 +147,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#properties
|
* @name Phaser.Tilemaps.LayerData#properties
|
||||||
* @type {object}
|
* @type {object}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -156,7 +156,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#indexes
|
* @name Phaser.Tilemaps.LayerData#indexes
|
||||||
* @type {array}
|
* @type {array}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -165,7 +165,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#collideIndexes
|
* @name Phaser.Tilemaps.LayerData#collideIndexes
|
||||||
* @type {array}
|
* @type {array}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -174,7 +174,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#callbacks
|
* @name Phaser.Tilemaps.LayerData#callbacks
|
||||||
* @type {array}
|
* @type {array}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -183,7 +183,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#bodies
|
* @name Phaser.Tilemaps.LayerData#bodies
|
||||||
* @type {array}
|
* @type {array}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -192,7 +192,7 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#data
|
* @name Phaser.Tilemaps.LayerData#data
|
||||||
* @type {array}
|
* @type {array}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
|
@ -201,9 +201,9 @@ var LayerData = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [description]
|
* [description]
|
||||||
*
|
*
|
||||||
* @name Phaser.Tilemaps.LayerData#tilemapLayer
|
* @name Phaser.Tilemaps.LayerData#tilemapLayer
|
||||||
* @type {Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer}
|
* @type {(Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer)}
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*/
|
*/
|
||||||
this.tilemapLayer = GetFastValue(config, 'tilemapLayer', null);
|
this.tilemapLayer = GetFastValue(config, 'tilemapLayer', null);
|
||||||
|
|
|
@ -21,7 +21,7 @@ var ParseWeltmeister = require('./impact/ParseWeltmeister');
|
||||||
*
|
*
|
||||||
* @param {string} name - The name of the tilemap, used to set the name on the MapData.
|
* @param {string} name - The name of the tilemap, used to set the name on the MapData.
|
||||||
* @param {integer} mapFormat - See ../Formats.js.
|
* @param {integer} mapFormat - See ../Formats.js.
|
||||||
* @param {integer[][]|string|object} data - 2D array, CSV string or Tiled JSON object.
|
* @param {(integer[][]|string|object)} data - 2D array, CSV string or Tiled JSON object.
|
||||||
* @param {integer} tileWidth - The width of a tile in pixels. Required for 2D array and CSV, but
|
* @param {integer} tileWidth - The width of a tile in pixels. Required for 2D array and CSV, but
|
||||||
* ignored for Tiled JSON.
|
* ignored for Tiled JSON.
|
||||||
* @param {integer} tileHeight - The height of a tile in pixels. Required for 2D array and CSV, but
|
* @param {integer} tileHeight - The height of a tile in pixels. Required for 2D array and CSV, but
|
||||||
|
|
|
@ -142,7 +142,7 @@ var StaticTilemapLayer = new Class({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @name Phaser.Tilemaps.StaticTilemapLayer#renderer
|
* @name Phaser.Tilemaps.StaticTilemapLayer#renderer
|
||||||
* @type {Phaser.Renderer.CanvasRenderer|Phaser.Renderer.WebGLRenderer}
|
* @type {(Phaser.Renderer.CanvasRenderer|Phaser.Renderer.WebGLRenderer)}
|
||||||
* @private
|
* @private
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*/
|
*/
|
||||||
|
@ -393,8 +393,8 @@ var StaticTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.StaticTilemapLayer#createFromTiles
|
* @method Phaser.Tilemaps.StaticTilemapLayer#createFromTiles
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - The tile index, or array of indexes, to create Sprites from.
|
* @param {(integer|array)} indexes - The tile index, or array of indexes, to create Sprites from.
|
||||||
* @param {integer|array} replacements - The tile index, or array of indexes, to change a converted
|
* @param {(integer|array)} replacements - The tile index, or array of indexes, to change a converted
|
||||||
* tile to. Set to `null` to leave the tiles unchanged. If an array is given, it is assumed to be a
|
* tile to. Set to `null` to leave the tiles unchanged. If an array is given, it is assumed to be a
|
||||||
* one-to-one mapping with the indexes array.
|
* one-to-one mapping with the indexes array.
|
||||||
* @param {object} spriteConfig - The config object to pass into the Sprite creator (i.e.
|
* @param {object} spriteConfig - The config object to pass into the Sprite creator (i.e.
|
||||||
|
@ -656,7 +656,7 @@ var StaticTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.StaticTilemapLayer#getTilesWithinShape
|
* @method Phaser.Tilemaps.StaticTilemapLayer#getTilesWithinShape
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {Phaser.Geom.Circle|Phaser.Geom.Line|Phaser.Geom.Rectangle|Phaser.Geom.Triangle} shape - A shape in world (pixel) coordinates
|
* @param {(Phaser.Geom.Circle|Phaser.Geom.Line|Phaser.Geom.Rectangle|Phaser.Geom.Triangle)} shape - A shape in world (pixel) coordinates
|
||||||
* @param {object} [filteringOptions] - Optional filters to apply when getting the tiles.
|
* @param {object} [filteringOptions] - Optional filters to apply when getting the tiles.
|
||||||
* @param {boolean} [filteringOptions.isNotEmpty=false] - If true, only return tiles that don't have
|
* @param {boolean} [filteringOptions.isNotEmpty=false] - If true, only return tiles that don't have
|
||||||
* -1 for an index.
|
* -1 for an index.
|
||||||
|
@ -743,7 +743,7 @@ var StaticTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.StaticTilemapLayer#setCollision
|
* @method Phaser.Tilemaps.StaticTilemapLayer#setCollision
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - Either a single tile index, or an array of tile indexes.
|
* @param {(integer|array)} indexes - Either a single tile index, or an array of tile indexes.
|
||||||
* @param {boolean} [collides=true] - If true it will enable collision. If false it will clear
|
* @param {boolean} [collides=true] - If true it will enable collision. If false it will clear
|
||||||
* collision.
|
* collision.
|
||||||
* @param {boolean} [recalculateFaces=true] - Whether or not to recalculate the tile faces after the
|
* @param {boolean} [recalculateFaces=true] - Whether or not to recalculate the tile faces after the
|
||||||
|
@ -843,7 +843,7 @@ var StaticTilemapLayer = new Class({
|
||||||
* @method Phaser.Tilemaps.StaticTilemapLayer#setTileIndexCallback
|
* @method Phaser.Tilemaps.StaticTilemapLayer#setTileIndexCallback
|
||||||
* @since 3.0.0
|
* @since 3.0.0
|
||||||
*
|
*
|
||||||
* @param {integer|array} indexes - Either a single tile index, or an array of tile indexes to have a
|
* @param {(integer|array)} indexes - Either a single tile index, or an array of tile indexes to have a
|
||||||
* collision callback set for.
|
* collision callback set for.
|
||||||
* @param {function} callback - The callback that will be invoked when the tile is collided with.
|
* @param {function} callback - The callback that will be invoked when the tile is collided with.
|
||||||
* @param {object} callbackContext - The context under which the callback is called.
|
* @param {object} callbackContext - The context under which the callback is called.
|
||||||
|
|
Loading…
Reference in a new issue