MCPcopy Create free account
hub / github.com/melonjs/melonJS / length2

Method length2

packages/melonjs/src/math/vector3d.ts:366–368  ·  view source on GitHub ↗

* return the square length of this vector * @returns The length^2 of this vector.

()

Source from the content-addressed store, hash-verified

364 * @returns The length^2 of this vector.
365 */
366 length2(): number {
367 return this.dot(this);
368 }
369
370 /**
371 * return the length (magnitude) of this vector

Callers 10

lengthMethod · 0.95
vornoiRegionFunction · 0.45
testEllipseEllipseFunction · 0.45
testPolygonEllipseFunction · 0.45
projectMethod · 0.45
projectNMethod · 0.45
vector2d.spec.tsFile · 0.45
vector3d.spec.tsFile · 0.45

Calls 1

dotMethod · 0.95

Tested by

no test coverage detected