jsdoc fixes

This commit is contained in:
Richard Davey 2018-03-28 15:39:57 +01:00
parent 747f09af86
commit f1e646c9ee
9 changed files with 92 additions and 22 deletions

View file

@ -13,7 +13,7 @@
* with other LITE or PASSIVE entities at all. The behavior for FIXED vs.
* FIXED collisions is undefined.
*
* @name Phaser.Physics.Impact.TYPES
* @name Phaser.Physics.Impact.TYPE
* @type {object}
* @since 3.0.0
*/
@ -22,7 +22,7 @@ module.exports = {
/**
* Collides with nothing.
*
* @name Phaser.Physics.Impact.TYPES.NONE
* @name Phaser.Physics.Impact.TYPE.NONE
* @type {integer}
* @since 3.0.0
*/
@ -31,7 +31,7 @@ module.exports = {
/**
* Type A. Collides with Type B.
*
* @name Phaser.Physics.Impact.TYPES.A
* @name Phaser.Physics.Impact.TYPE.A
* @type {integer}
* @since 3.0.0
*/
@ -40,7 +40,7 @@ module.exports = {
/**
* Type B. Collides with Type A.
*
* @name Phaser.Physics.Impact.TYPES.B
* @name Phaser.Physics.Impact.TYPE.B
* @type {integer}
* @since 3.0.0
*/
@ -49,7 +49,7 @@ module.exports = {
/**
* Collides with both types A and B.
*
* @name Phaser.Physics.Impact.TYPES.BOTH
* @name Phaser.Physics.Impact.TYPE.BOTH
* @type {integer}
* @since 3.0.0
*/

View file

@ -23,7 +23,6 @@ var TYPE = require('./TYPE');
* @property {number} [cellSize=64] - [description]
* @property {number} [timeScale=1] - [description]
* @property {float} [maxStep=0.05] - [description]
* @property {number} [gravity=0] - [description]
* @property {boolean} [debug=false] - [description]
* @property {number} [maxVelocity=100] - [description]
* @property {boolean} [debugShowBody=true] - [description]
@ -38,7 +37,6 @@ var TYPE = require('./TYPE');
* @property {(object|boolean)} [setBounds] - [description]
* @property {number} [setBounds.x=0] - [description]
* @property {number} [setBounds.y=0] - [description]
* @property {number} [setBounds.x=0] - [description]
* @property {number} [setBounds.width] - [description]
* @property {number} [setBounds.height] - [description]
* @property {number} [setBounds.thickness=64] - [description]
@ -334,7 +332,7 @@ var World = new Class({
* @method Phaser.Physics.Impact.World#setCollisionMapFromTilemapLayer
* @since 3.0.0
*
* @param {(StaticTilemapLayer|DynamicTilemapLayer)} tilemapLayer - The tilemap layer to use.
* @param {(Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer)} tilemapLayer - The tilemap layer to use.
* @param {object} [options] - Options for controlling the mapping from tiles to slope IDs.
* @param {string} [options.slopeTileProperty=null] - Slope IDs can be stored on tiles directly
* using Tiled's tileset editor. If a tile has a property with the given slopeTileProperty string

View file

@ -530,7 +530,7 @@ var Factory = new Class({
* @param {(string|integer)} [frame] - An optional frame from the Texture this Game Object is rendering with. Set to `null` to skip this value.
* @param {object} [options={}] - [description]
*
* @return {Phaser.Physics.Matter.MatterImage} [description]
* @return {Phaser.Physics.Matter.Image} [description]
*/
image: function (x, y, key, frame, options)
{
@ -547,10 +547,10 @@ var Factory = new Class({
* @method Phaser.Physics.Matter.Factory#tileBody
* @since 3.0.0
*
* @param {Phaser.GameObjects.Tile} tile - [description]
* @param {Phaser.Tilemaps.Tile} tile - [description]
* @param {object} options - [description]
*
* @return {Phaser.Physics.Matter.MatterTileBody} [description]
* @return {Phaser.Physics.Matter.TileBody} [description]
*/
tileBody: function (tile, options)
{
@ -571,7 +571,7 @@ var Factory = new Class({
* @param {(string|integer)} [frame] - An optional frame from the Texture this Game Object is rendering with. Set to `null` to skip this value.
* @param {object} [options={}] - [description]
*
* @return {Phaser.Physics.Matter.MatterSprite} [description]
* @return {Phaser.Physics.Matter.Sprite} [description]
*/
sprite: function (x, y, key, frame, options)
{

View file

@ -40,7 +40,7 @@ var Vertices = require('./lib/geometry/Vertices');
* @extends Phaser.Physics.Matter.Components.Static
*
* @param {Phaser.Physics.Matter.World} world - [description]
* @param {Phaser.GameObjects.Tile} tile - The target tile that should have a Matter body.
* @param {Phaser.Tilemaps.Tile} tile - The target tile that should have a Matter body.
* @param {object} [options] - Options to be used when creating the Matter body. See
* Phaser.Physics.Matter.Matter.Body for a list of what Matter accepts.
* @param {Phaser.Physics.Matter.Matter.Body} [options.body=null] - An existing Matter body to
@ -71,7 +71,7 @@ var MatterTileBody = new Class({
* The tile object the body is associated with.
*
* @name Phaser.Physics.Matter.TileBody#tile
* @type {Phaser.GameObjects.Tile}
* @type {Phaser.Tilemaps.Tile}
* @since 3.0.0
*/
this.tile = tile;

View file

@ -530,7 +530,7 @@ var World = new Class({
* @method Phaser.Physics.Matter.World#convertTilemapLayer
* @since 3.0.0
*
* @param {(Phaser.GameObjects.StaticTilemapLayer|Phaser.GameObjects.DynamicTilemapLayer)} tilemapLayer -
* @param {(Phaser.Tilemaps.DynamicTilemapLayer|Phaser.Tilemaps.StaticTilemapLayer)} tilemapLayer -
* An array of tiles.
* @param {object} [options] - Options to be passed to the MatterTileBody constructor. {@ee Phaser.Physics.Matter.TileBody}
*
@ -553,7 +553,7 @@ var World = new Class({
* @method Phaser.Physics.Matter.World#convertTiles
* @since 3.0.0
*
* @param {Phaser.GameObjects.Tile[]} tiles - An array of tiles.
* @param {Phaser.Tilemaps.Tile[]} tiles - An array of tiles.
* @param {object} [options] - Options to be passed to the MatterTileBody constructor. {@see Phaser.Physics.Matter.TileBody}
*
* @return {Phaser.Physics.Matter.World} This Matter World object.

View file

@ -20,3 +20,60 @@ module.exports = {
World: require('./World')
};
/**
* @namespace Matter
*/
/**
* @classdesc
* The `Matter.Body` module contains methods for creating and manipulating body models.
* A `Matter.Body` is a rigid body that can be simulated by a `Matter.Engine`.
* Factories for commonly used body configurations (such as rectangles, circles and other polygons) can be found in the module `Matter.Bodies`.
*
* @class Body
* @memberOf Matter
*/
/**
* @classdesc
* The `Matter.Composite` module contains methods for creating and manipulating composite bodies.
* A composite body is a collection of `Matter.Body`, `Matter.Constraint` and other `Matter.Composite`, therefore composites form a tree structure.
* It is important to use the functions in this module to modify composites, rather than directly modifying their properties.
* Note that the `Matter.World` object is also a type of `Matter.Composite` and as such all composite methods here can also operate on a `Matter.World`.
*
* @class Composite
* @memberOf Matter
*/
/**
* @classdesc
* The `Matter.World` module contains methods for creating and manipulating the world composite.
* A `Matter.World` is a `Matter.Composite` body, which is a collection of `Matter.Body`, `Matter.Constraint` and other `Matter.Composite`.
* A `Matter.World` has a few additional properties including `gravity` and `bounds`.
* It is important to use the functions in the `Matter.Composite` module to modify the world composite, rather than directly modifying its properties.
* There are also a few methods here that alias those in `Matter.Composite` for easier readability.
*
* @class World
* @extends Matter.Composite
* @memberOf Matter
*/
/**
* @classdesc
* The `Matter.Constraint` module contains methods for creating and manipulating constraints.
* Constraints are used for specifying that a fixed distance must be maintained between two bodies (or a body and a fixed world-space position).
* The stiffness of constraints can be modified to create springs or elastic.
*
* @class Constraint
* @memberOf Matter
*/
/**
* @classdesc
* The `Matter.Engine` module contains methods for creating and manipulating engines.
* An engine is a controller that manages updating the simulation of the world.
*
* @class Engine
* @memberOf Matter
*/

View file

@ -10,8 +10,8 @@
module.exports = {
CanvasRenderer: require('./CanvasRenderer'),
BlitImage: require('./utils/BlitImage'),
CanvasRenderer: require('./CanvasRenderer'),
DrawImage: require('./utils/DrawImage'),
GetBlendModes: require('./utils/GetBlendModes')

View file

@ -111,7 +111,7 @@ var Systems = new Class({
* [description]
*
* @name Phaser.Scenes.Systems#plugins
* @type {Phaser.Plugins.PluginManager}
* @type {Phaser.Boot.PluginManager}
* @since 3.0.0
*/
this.plugins;

View file

@ -18,11 +18,26 @@ var Textures = {
Frame: require('./Frame'),
Texture: require('./Texture'),
TextureManager: require('./TextureManager'),
TextureSource: require('./TextureSource')
TextureSource: require('./TextureSource'),
/**
* Linear filter type.
*
* @name Phaser.Textures.LINEAR
* @type {integer}
* @since 3.0.0
*/
LINEAR: 0,
/**
* Nearest neighbor filter type.
*
* @name Phaser.Textures.NEAREST
* @type {integer}
* @since 3.0.0
*/
NEAREST: 1
};
// Merge in the consts
Textures = Extend(false, Textures, CONST);
module.exports = Textures;