type errors fixed

This commit is contained in:
Richard Davey 2024-11-14 23:06:27 +00:00
parent a6f8dc8b25
commit f0ad396974
No known key found for this signature in database
12 changed files with 27 additions and 25 deletions

View file

@ -175,7 +175,7 @@ var Curve = new Class({
*
* @param {number} distance - The distance, in pixels, between each point along the curve.
*
* @return {Phaser.Geom.Point[]} An Array of Point objects.
* @return {Phaser.Math.Vector2[]} An Array of Vector2 objects.
*/
getDistancePoints: function (distance)
{
@ -317,9 +317,9 @@ var Curve = new Class({
*
* @param {number} [divisions] - The number of divisions to make.
* @param {number} [stepRate] - The curve distance between points, implying `divisions`.
* @param {(array|Phaser.Math.Vector2[])} [out] - An optional array to store the points in.
* @param {Phaser.Math.Vector2[]} [out] - An optional array to store the points in.
*
* @return {(array|Phaser.Math.Vector2[])} An array of Points from the curve.
* @return {Phaser.Math.Vector2[]} An array of Vector2 points from the curve.
*/
getPoints: function (divisions, stepRate, out)
{
@ -377,9 +377,9 @@ var Curve = new Class({
*
* @param {number} [divisions=this.defaultDivisions] - The number of divisions to make.
* @param {number} [stepRate] - Step between points. Used to calculate the number of points to return when divisions is falsy. Ignored if divisions is positive.
* @param {(array|Phaser.Math.Vector2[])} [out] - An optional array to store the points in.
* @param {Phaser.Math.Vector2[]} [out] - An optional array to store the points in.
*
* @return {Phaser.Math.Vector2[]} An array of points.
* @return {Phaser.Math.Vector2[]} An array of Vector2 points.
*/
getSpacedPoints: function (divisions, stepRate, out)
{

View file

@ -467,7 +467,7 @@ var Container = new Class({
},
/**
* Takes a Point-like object, such as a Vector2, Geom.Point or object with public x and y properties,
* Takes a Point-like object, such as a Vector2, or object with public x and y properties,
* and transforms it into the space of this Container, then returns it in the output object.
*
* @method Phaser.GameObjects.Container#pointToContainer

View file

@ -892,7 +892,7 @@ var Graphics = new Class({
* @method Phaser.GameObjects.Graphics#fillPointShape
* @since 3.0.0
*
* @param {(Phaser.Geom.Point|Phaser.Math.Vector2|object)} point - The point to fill.
* @param {Phaser.Math.Vector2} point - The point to fill.
* @param {number} [size=1] - The size of the square to draw.
*
* @return {this} This Game Object.
@ -1108,7 +1108,7 @@ var Graphics = new Class({
* @method Phaser.GameObjects.Graphics#strokePoints
* @since 3.0.0
*
* @param {(array|Phaser.Geom.Point[])} points - The points to stroke.
* @param {Phaser.Math.Vector2[]} points - The points to stroke.
* @param {boolean} [closeShape=false] - When `true`, the shape is closed by joining the last point to the first point.
* @param {boolean} [closePath=false] - When `true`, the path is closed before being stroked.
* @param {number} [endIndex] - The index of `points` to stop drawing at. Defaults to `points.length`.
@ -1155,7 +1155,7 @@ var Graphics = new Class({
* @method Phaser.GameObjects.Graphics#fillPoints
* @since 3.0.0
*
* @param {(array|Phaser.Geom.Point[])} points - The points to fill.
* @param {Phaser.Math.Vector2[]} points - The points to fill.
* @param {boolean} [closeShape=false] - When `true`, the shape is closed by joining the last point to the first point.
* @param {boolean} [closePath=false] - When `true`, the path is closed before being stroked.
* @param {number} [endIndex] - The index of `points` to stop at. Defaults to `points.length`.

View file

@ -95,7 +95,7 @@ var Group = new Class({
* Members of this group.
*
* @name Phaser.GameObjects.Group#children
* @type {Phaser.Structs.Set.<Phaser.GameObjects.GameObject>}
* @type {Set.<Phaser.GameObjects.GameObject>}
* @since 3.0.0
*/
this.children = new Set();

View file

@ -45,7 +45,7 @@ var EdgeZone = new Class({
* The points placed on the source edge.
*
* @name Phaser.GameObjects.Particles.Zones.EdgeZone#points
* @type {Phaser.Geom.Point[]}
* @type {Phaser.Math.Vector2[]}
* @default []
* @since 3.0.0
*/

View file

@ -99,7 +99,7 @@ var Rope = new Class({
/**
* An array containing the points data for this Rope.
*
* Each point should be given as a Vector2Like object (i.e. a Vector2, Geom.Point or object with public x/y properties).
* Each point should be given as a Vector2Like object (i.e. a Vector2 or object with public x/y properties).
*
* The point coordinates are given in local space, where 0 x 0 is the start of the Rope strip.
*

View file

@ -261,7 +261,7 @@ var LoaderPlugin = new Class({
* By the end of the load process this Set will be empty.
*
* @name Phaser.Loader.LoaderPlugin#list
* @type {Phaser.Structs.Set.<Phaser.Loader.File>}
* @type {Set.<Phaser.Loader.File>}
* @since 3.0.0
*/
this.list = new Set();
@ -274,7 +274,7 @@ var LoaderPlugin = new Class({
* By the end of the load process this Set will be empty.
*
* @name Phaser.Loader.LoaderPlugin#inflight
* @type {Phaser.Structs.Set.<Phaser.Loader.File>}
* @type {Set.<Phaser.Loader.File>}
* @since 3.0.0
*/
this.inflight = new Set();
@ -288,7 +288,7 @@ var LoaderPlugin = new Class({
* At the end of the load process this Set will be empty.
*
* @name Phaser.Loader.LoaderPlugin#queue
* @type {Phaser.Structs.Set.<Phaser.Loader.File>}
* @type {Set.<Phaser.Loader.File>}
* @since 3.0.0
*/
this.queue = new Set();
@ -298,7 +298,7 @@ var LoaderPlugin = new Class({
* awaiting destruction at the end of the load process.
*
* @name Phaser.Loader.LoaderPlugin#_deleteQueue
* @type {Phaser.Structs.Set.<Phaser.Loader.File>}
* @type {Set.<Phaser.Loader.File>}
* @private
* @since 3.7.0
*/

View file

@ -9,11 +9,13 @@
*
* @function Phaser.Math.Rotate
* @since 3.0.0
*
* @generic {Phaser.Types.Math.Vector2Like} T - [point,$return]
*
* @param {(Phaser.Geom.Point|object)} point - The point to be rotated.
* @param {Phaser.Types.Math.Vector2Like} point - The point to be rotated.
* @param {number} angle - The angle to be rotated by in an anticlockwise direction.
*
* @return {Phaser.Geom.Point} The given point, rotated by the given angle in an anticlockwise direction.
* @return {Phaser.Types.Math.Vector2Like} The given point, rotated by the given angle in an anticlockwise direction.
*/
var Rotate = function (point, angle)
{

View file

@ -14,7 +14,7 @@
*
* @generic {Phaser.Types.Math.Vector2Like} T - [point,$return]
*
* @param {(Phaser.Geom.Point|object)} point - The point to be rotated.
* @param {Phaser.Types.Math.Vector2Like} point - The point to be rotated.
* @param {number} x - The horizontal coordinate to rotate around.
* @param {number} y - The vertical coordinate to rotate around.
* @param {number} angle - The angle of rotation in radians.

View file

@ -14,7 +14,7 @@
*
* @generic {Phaser.Types.Math.Vector2Like} T - [point,$return]
*
* @param {(Phaser.Geom.Point|object)} point - The point to be rotated.
* @param {Phaser.Types.Math.Vector2Like} point - The point to be rotated.
* @param {number} x - The horizontal coordinate to rotate around.
* @param {number} y - The vertical coordinate to rotate around.
* @param {number} angle - The angle of rotation in radians.

View file

@ -20,9 +20,9 @@ var Vector2 = require('./Vector2');
* @param {number} rotation - Rotation of the transform point, in radians.
* @param {number} scaleX - Horizontal scale of the transform point.
* @param {number} scaleY - Vertical scale of the transform point.
* @param {(Phaser.Math.Vector2|Phaser.Geom.Point|object)} [output] - The output vector, point or object for the translated coordinates.
* @param {Phaser.Types.Math.Vector2Like} [output] - The output vector, point or object for the translated coordinates.
*
* @return {(Phaser.Math.Vector2|Phaser.Geom.Point|object)} The translated point.
* @return {Phaser.Types.Math.Vector2Like} The translated point.
*/
var TransformXY = function (x, y, positionX, positionY, rotation, scaleX, scaleY, output)
{

View file

@ -75,7 +75,7 @@ var World = new Class({
* Dynamic Bodies in this simulation.
*
* @name Phaser.Physics.Arcade.World#bodies
* @type {Phaser.Structs.Set.<Phaser.Physics.Arcade.Body>}
* @type {Set.<Phaser.Physics.Arcade.Body>}
* @since 3.0.0
*/
this.bodies = new Set();
@ -84,7 +84,7 @@ var World = new Class({
* Static Bodies in this simulation.
*
* @name Phaser.Physics.Arcade.World#staticBodies
* @type {Phaser.Structs.Set.<Phaser.Physics.Arcade.StaticBody>}
* @type {Set.<Phaser.Physics.Arcade.StaticBody>}
* @since 3.0.0
*/
this.staticBodies = new Set();
@ -93,7 +93,7 @@ var World = new Class({
* Static Bodies marked for deletion.
*
* @name Phaser.Physics.Arcade.World#pendingDestroy
* @type {Phaser.Structs.Set.<(Phaser.Physics.Arcade.Body|Phaser.Physics.Arcade.StaticBody)>}
* @type {Set.<(Phaser.Physics.Arcade.Body|Phaser.Physics.Arcade.StaticBody)>}
* @since 3.1.0
*/
this.pendingDestroy = new Set();