Update JSDoc on "Impact" physics

This commit is contained in:
orblazer 2018-03-19 00:42:09 +01:00
parent af3c03a3cb
commit 2da6a2bffe
18 changed files with 103 additions and 104 deletions

View file

@ -539,7 +539,7 @@ var Body = new Class({
* @since 3.0.0 * @since 3.0.0
* *
* @param {Phaser.Physics.Impact.Body} other - [description] * @param {Phaser.Physics.Impact.Body} other - [description]
* @param {[type]} axis - [description] * @param {string} axis - [description]
*/ */
collideWith: function (other, axis) collideWith: function (other, axis)
{ {

View file

@ -15,7 +15,6 @@
* *
* @namespace Phaser.Physics.Impact.COLLIDES * @namespace Phaser.Physics.Impact.COLLIDES
*/ */
module.exports = { module.exports = {
/** /**

View file

@ -97,7 +97,7 @@ var Factory = new Class({
* *
* @param {number} x - The horizontal position of this Game Object in the world. * @param {number} x - The horizontal position of this Game Object in the world.
* @param {number} y - The vertical position of this Game Object in the world. * @param {number} y - The vertical position of this Game Object in the world.
* @param {string} texture - The key of the Texture this Game Object will use to render with, as stored in the Texture Manager. * @param {string} key - The key of the Texture this Game Object will use to render with, as stored in the Texture Manager.
* @param {string|integer} [frame] - An optional frame from the Texture this Game Object is rendering with. * @param {string|integer} [frame] - An optional frame from the Texture this Game Object is rendering with.
* *
* @return {Phaser.Physics.Impact.ImpactImage} The ImpactImage object that was created. * @return {Phaser.Physics.Impact.ImpactImage} The ImpactImage object that was created.
@ -119,7 +119,7 @@ var Factory = new Class({
* *
* @param {number} x - The horizontal position of this Game Object in the world. * @param {number} x - The horizontal position of this Game Object in the world.
* @param {number} y - The vertical position of this Game Object in the world. * @param {number} y - The vertical position of this Game Object in the world.
* @param {string} texture - The key of the Texture this Game Object will use to render with, as stored in the Texture Manager. * @param {string} key - The key of the Texture this Game Object will use to render with, as stored in the Texture Manager.
* @param {string|integer} [frame] - An optional frame from the Texture this Game Object is rendering with. * @param {string|integer} [frame] - An optional frame from the Texture this Game Object is rendering with.
* *
* @return {Phaser.Physics.Impact.ImpactSprite} The ImpactSprite object that was created. * @return {Phaser.Physics.Impact.ImpactSprite} The ImpactSprite object that was created.

View file

@ -15,7 +15,6 @@
* *
* @namespace Phaser.Physics.Impact.TYPES * @namespace Phaser.Physics.Impact.TYPES
*/ */
module.exports = { module.exports = {
/** /**

View file

@ -18,9 +18,9 @@ var Acceleration = {
* @method Phaser.Physics.Impact.Components.Acceleration#setAccelerationX * @method Phaser.Physics.Impact.Components.Acceleration#setAccelerationX
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} x - [description] * @param {number} x - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setAccelerationX: function (x) setAccelerationX: function (x)
{ {
@ -35,9 +35,9 @@ var Acceleration = {
* @method Phaser.Physics.Impact.Components.Acceleration#setAccelerationY * @method Phaser.Physics.Impact.Components.Acceleration#setAccelerationY
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} y - [description] * @param {number} y - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setAccelerationY: function (y) setAccelerationY: function (y)
{ {
@ -52,10 +52,10 @@ var Acceleration = {
* @method Phaser.Physics.Impact.Components.Acceleration#setAcceleration * @method Phaser.Physics.Impact.Components.Acceleration#setAcceleration
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} x - [description] * @param {number} x - [description]
* @param {[type]} y - [description] * @param {number} y - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setAcceleration: function (x, y) setAcceleration: function (x, y)
{ {

View file

@ -18,10 +18,10 @@ var BodyScale = {
* @method Phaser.Physics.Impact.Components.BodyScale#setBodySize * @method Phaser.Physics.Impact.Components.BodyScale#setBodySize
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} width - [description] * @param {number} width - [description]
* @param {[type]} height - [description] * @param {number} [height=width] - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setBodySize: function (width, height) setBodySize: function (width, height)
{ {
@ -39,10 +39,10 @@ var BodyScale = {
* @method Phaser.Physics.Impact.Components.BodyScale#setBodyScale * @method Phaser.Physics.Impact.Components.BodyScale#setBodyScale
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} scaleX - [description] * @param {number} scaleX - [description]
* @param {[type]} scaleY - [description] * @param {number} [scaleY] - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setBodyScale: function (scaleX, scaleY) setBodyScale: function (scaleX, scaleY)
{ {

View file

@ -20,7 +20,7 @@ var BodyType = {
* @method Phaser.Physics.Impact.Components.BodyType#getBodyType * @method Phaser.Physics.Impact.Components.BodyType#getBodyType
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {number} [description]
*/ */
getBodyType: function () getBodyType: function ()
{ {
@ -33,7 +33,7 @@ var BodyType = {
* @method Phaser.Physics.Impact.Components.BodyType#setTypeNone * @method Phaser.Physics.Impact.Components.BodyType#setTypeNone
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setTypeNone: function () setTypeNone: function ()
{ {
@ -48,7 +48,7 @@ var BodyType = {
* @method Phaser.Physics.Impact.Components.BodyType#setTypeA * @method Phaser.Physics.Impact.Components.BodyType#setTypeA
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setTypeA: function () setTypeA: function ()
{ {
@ -63,7 +63,7 @@ var BodyType = {
* @method Phaser.Physics.Impact.Components.BodyType#setTypeB * @method Phaser.Physics.Impact.Components.BodyType#setTypeB
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setTypeB: function () setTypeB: function ()
{ {

View file

@ -18,9 +18,9 @@ var Bounce = {
* @method Phaser.Physics.Impact.Components.Bounce#setBounce * @method Phaser.Physics.Impact.Components.Bounce#setBounce
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} value - [description] * @param {number} value - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setBounce: function (value) setBounce: function (value)
{ {
@ -35,9 +35,9 @@ var Bounce = {
* @method Phaser.Physics.Impact.Components.Bounce#setMinBounceVelocity * @method Phaser.Physics.Impact.Components.Bounce#setMinBounceVelocity
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} value - [description] * @param {number} value - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setMinBounceVelocity: function (value) setMinBounceVelocity: function (value)
{ {
@ -50,7 +50,7 @@ var Bounce = {
* [description] * [description]
* *
* @name Phaser.Physics.Impact.Components.Bounce#bounce * @name Phaser.Physics.Impact.Components.Bounce#bounce
* @type {[type]} * @type {number}
* @since 3.0.0 * @since 3.0.0
*/ */
bounce: { bounce: {

View file

@ -20,7 +20,7 @@ var CheckAgainst = {
* @method Phaser.Physics.Impact.Components.CheckAgainst#setAvsB * @method Phaser.Physics.Impact.Components.CheckAgainst#setAvsB
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setAvsB: function () setAvsB: function ()
{ {
@ -35,7 +35,7 @@ var CheckAgainst = {
* @method Phaser.Physics.Impact.Components.CheckAgainst#setBvsA * @method Phaser.Physics.Impact.Components.CheckAgainst#setBvsA
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setBvsA: function () setBvsA: function ()
{ {
@ -50,7 +50,7 @@ var CheckAgainst = {
* @method Phaser.Physics.Impact.Components.CheckAgainst#setCheckAgainstNone * @method Phaser.Physics.Impact.Components.CheckAgainst#setCheckAgainstNone
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setCheckAgainstNone: function () setCheckAgainstNone: function ()
{ {
@ -65,7 +65,7 @@ var CheckAgainst = {
* @method Phaser.Physics.Impact.Components.CheckAgainst#setCheckAgainstA * @method Phaser.Physics.Impact.Components.CheckAgainst#setCheckAgainstA
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setCheckAgainstA: function () setCheckAgainstA: function ()
{ {
@ -80,7 +80,7 @@ var CheckAgainst = {
* @method Phaser.Physics.Impact.Components.CheckAgainst#setCheckAgainstB * @method Phaser.Physics.Impact.Components.CheckAgainst#setCheckAgainstB
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setCheckAgainstB: function () setCheckAgainstB: function ()
{ {
@ -93,7 +93,7 @@ var CheckAgainst = {
* [description] * [description]
* *
* @name Phaser.Physics.Impact.Components.CheckAgainst#checkAgainst * @name Phaser.Physics.Impact.Components.CheckAgainst#checkAgainst
* @type {[type]} * @type {number}
* @since 3.0.0 * @since 3.0.0
*/ */
checkAgainst: { checkAgainst: {

View file

@ -23,10 +23,10 @@ var Collides = {
* @method Phaser.Physics.Impact.Components.Collides#setCollideCallback * @method Phaser.Physics.Impact.Components.Collides#setCollideCallback
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} callback - [description] * @param {function} callback - [description]
* @param {[type]} scope - [description] * @param {object} scope - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setCollideCallback: function (callback, scope) setCollideCallback: function (callback, scope)
{ {
@ -46,7 +46,7 @@ var Collides = {
* @method Phaser.Physics.Impact.Components.Collides#setCollidesNever * @method Phaser.Physics.Impact.Components.Collides#setCollidesNever
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setCollidesNever: function () setCollidesNever: function ()
{ {
@ -61,7 +61,7 @@ var Collides = {
* @method Phaser.Physics.Impact.Components.Collides#setLite * @method Phaser.Physics.Impact.Components.Collides#setLite
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setLite: function () setLite: function ()
{ {
@ -76,7 +76,7 @@ var Collides = {
* @method Phaser.Physics.Impact.Components.Collides#setPassive * @method Phaser.Physics.Impact.Components.Collides#setPassive
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setPassive: function () setPassive: function ()
{ {
@ -91,7 +91,7 @@ var Collides = {
* @method Phaser.Physics.Impact.Components.Collides#setActive * @method Phaser.Physics.Impact.Components.Collides#setActive
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setActive: function () setActive: function ()
{ {
@ -106,7 +106,7 @@ var Collides = {
* @method Phaser.Physics.Impact.Components.Collides#setFixed * @method Phaser.Physics.Impact.Components.Collides#setFixed
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setFixed: function () setFixed: function ()
{ {
@ -119,7 +119,7 @@ var Collides = {
* [description] * [description]
* *
* @name Phaser.Physics.Impact.Components.Collides#collides * @name Phaser.Physics.Impact.Components.Collides#collides
* @type {[type]} * @type {number}
* @since 3.0.0 * @since 3.0.0
*/ */
collides: { collides: {

View file

@ -18,11 +18,11 @@ var Debug = {
* @method Phaser.Physics.Impact.Components.Debug#setDebug * @method Phaser.Physics.Impact.Components.Debug#setDebug
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} showBody - [description] * @param {boolean} showBody - [description]
* @param {[type]} showVelocity - [description] * @param {boolean} showVelocity - [description]
* @param {[type]} bodyColor - [description] * @param {number} bodyColor - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setDebug: function (showBody, showVelocity, bodyColor) setDebug: function (showBody, showVelocity, bodyColor)
{ {
@ -39,9 +39,9 @@ var Debug = {
* @method Phaser.Physics.Impact.Components.Debug#setDebugBodyColor * @method Phaser.Physics.Impact.Components.Debug#setDebugBodyColor
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} value - [description] * @param {number} value - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setDebugBodyColor: function (value) setDebugBodyColor: function (value)
{ {
@ -54,7 +54,7 @@ var Debug = {
* [description] * [description]
* *
* @name Phaser.Physics.Impact.Components.Debug#debugShowBody * @name Phaser.Physics.Impact.Components.Debug#debugShowBody
* @type {[type]} * @type {boolean}
* @since 3.0.0 * @since 3.0.0
*/ */
debugShowBody: { debugShowBody: {
@ -75,7 +75,7 @@ var Debug = {
* [description] * [description]
* *
* @name Phaser.Physics.Impact.Components.Debug#debugShowVelocity * @name Phaser.Physics.Impact.Components.Debug#debugShowVelocity
* @type {[type]} * @type {boolean}
* @since 3.0.0 * @since 3.0.0
*/ */
debugShowVelocity: { debugShowVelocity: {
@ -96,7 +96,7 @@ var Debug = {
* [description] * [description]
* *
* @name Phaser.Physics.Impact.Components.Debug#debugBodyColor * @name Phaser.Physics.Impact.Components.Debug#debugBodyColor
* @type {[type]} * @type {number}
* @since 3.0.0 * @since 3.0.0
*/ */
debugBodyColor: { debugBodyColor: {

View file

@ -18,9 +18,9 @@ var Friction = {
* @method Phaser.Physics.Impact.Components.Friction#setFrictionX * @method Phaser.Physics.Impact.Components.Friction#setFrictionX
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} x - [description] * @param {number} x - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setFrictionX: function (x) setFrictionX: function (x)
{ {
@ -35,9 +35,9 @@ var Friction = {
* @method Phaser.Physics.Impact.Components.Friction#setFrictionY * @method Phaser.Physics.Impact.Components.Friction#setFrictionY
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} y - [description] * @param {number} y - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setFrictionY: function (y) setFrictionY: function (y)
{ {
@ -52,10 +52,10 @@ var Friction = {
* @method Phaser.Physics.Impact.Components.Friction#setFriction * @method Phaser.Physics.Impact.Components.Friction#setFriction
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} x - [description] * @param {number} x - [description]
* @param {[type]} y - [description] * @param {number} y - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setFriction: function (x, y) setFriction: function (x, y)
{ {

View file

@ -18,9 +18,9 @@ var Gravity = {
* @method Phaser.Physics.Impact.Components.Gravity#setGravity * @method Phaser.Physics.Impact.Components.Gravity#setGravity
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} value - [description] * @param {number} value - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setGravity: function (value) setGravity: function (value)
{ {
@ -33,7 +33,7 @@ var Gravity = {
* [description] * [description]
* *
* @name Phaser.Physics.Impact.Components.Gravity#gravity * @name Phaser.Physics.Impact.Components.Gravity#gravity
* @type {[type]} * @type {number}
* @since 3.0.0 * @since 3.0.0
*/ */
gravity: { gravity: {

View file

@ -18,12 +18,12 @@ var Offset = {
* @method Phaser.Physics.Impact.Components.Offset#setOffset * @method Phaser.Physics.Impact.Components.Offset#setOffset
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} x - [description] * @param {number} x - [description]
* @param {[type]} y - [description] * @param {number} y - [description]
* @param {[type]} width - [description] * @param {number} [width] - [description]
* @param {[type]} height - [description] * @param {number} [height] - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setOffset: function (x, y, width, height) setOffset: function (x, y, width, height)
{ {

View file

@ -18,10 +18,10 @@ var SetGameObject = {
* @method Phaser.Physics.Impact.Components.SetGameObject#setGameObject * @method Phaser.Physics.Impact.Components.SetGameObject#setGameObject
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} gameObject - [description] * @param {Phaser.GameObjects.GameObject} gameObject - [description]
* @param {[type]} sync - [description] * @param {boolean} [sync=true] - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setGameObject: function (gameObject, sync) setGameObject: function (gameObject, sync)
{ {
@ -50,7 +50,7 @@ var SetGameObject = {
* @method Phaser.Physics.Impact.Components.SetGameObject#syncGameObject * @method Phaser.Physics.Impact.Components.SetGameObject#syncGameObject
* @since 3.0.0 * @since 3.0.0
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
syncGameObject: function () syncGameObject: function ()
{ {

View file

@ -18,9 +18,9 @@ var Velocity = {
* @method Phaser.Physics.Impact.Components.Velocity#setVelocityX * @method Phaser.Physics.Impact.Components.Velocity#setVelocityX
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} x - [description] * @param {number} x - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setVelocityX: function (x) setVelocityX: function (x)
{ {
@ -35,9 +35,9 @@ var Velocity = {
* @method Phaser.Physics.Impact.Components.Velocity#setVelocityY * @method Phaser.Physics.Impact.Components.Velocity#setVelocityY
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} y - [description] * @param {number} y - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setVelocityY: function (y) setVelocityY: function (y)
{ {
@ -52,10 +52,10 @@ var Velocity = {
* @method Phaser.Physics.Impact.Components.Velocity#setVelocity * @method Phaser.Physics.Impact.Components.Velocity#setVelocity
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} x - [description] * @param {number} x - [description]
* @param {[type]} y - [description] * @param {number} [y=x] - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setVelocity: function (x, y) setVelocity: function (x, y)
{ {
@ -73,10 +73,10 @@ var Velocity = {
* @method Phaser.Physics.Impact.Components.Velocity#setMaxVelocity * @method Phaser.Physics.Impact.Components.Velocity#setMaxVelocity
* @since 3.0.0 * @since 3.0.0
* *
* @param {[type]} x - [description] * @param {number} x - [description]
* @param {[type]} y - [description] * @param {number} [y=x] - [description]
* *
* @return {[type]} [description] * @return {Phaser.GameObjects.GameObject} This Game Object.
*/ */
setMaxVelocity: function (x, y) setMaxVelocity: function (x, y)
{ {

View file

@ -4,7 +4,9 @@
* @license {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License} * @license {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License}
*/ */
// Phaser.Physics.Impact.Body.Components /**
* @namespace Phaser.Physics.Impact.Body.Components
*/
module.exports = { module.exports = {

View file

@ -19,7 +19,6 @@
* *
* @namespace Phaser.Physics.Impact * @namespace Phaser.Physics.Impact
*/ */
module.exports = { module.exports = {
Body: require('./Body'), Body: require('./Body'),