Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Vector3

Hierarchy

  • Vector3

Implements

Index

Constructors

constructor

  • Returns Vector3

  • Parameters

    Returns Vector3

  • Parameters

    Returns Vector3

  • Parameters

    • x: number
    • y: number
    • z: number

    Returns Vector3

Accessors

x

  • get x(): number
  • set x(value: number): void
  • Returns number

  • Parameters

    • value: number

    Returns void

xy

  • get xy(): []
  • set xy(values: []): void
  • Returns []

  • Parameters

    • values: []

    Returns void

xyz

  • get xyz(): []
  • set xyz(values: []): void
  • Returns []

  • Parameters

    • values: []

    Returns void

xz

  • get xz(): []
  • set xz(values: []): void
  • Returns []

  • Parameters

    • values: []

    Returns void

y

  • get y(): number
  • set y(value: number): void
  • Returns number

  • Parameters

    • value: number

    Returns void

yz

  • get yz(): []
  • set yz(values: []): void
  • Returns []

  • Parameters

    • values: []

    Returns void

z

  • get z(): number
  • set z(value: number): void
  • Returns number

  • Parameters

    • value: number

    Returns void

Static FORWARD

  • Returns Vector3

Static ONE

  • Returns Vector3

Static RIGHT

  • Returns Vector3

Static UP

  • Returns Vector3

Static ZERO

  • Returns Vector3

Methods

add

  • Parameters

    Returns this

at

  • at(index: number): number
  • Parameters

    • index: number

    Returns number

copy

  • copy(): Vector3
  • copy<D>(dest: D): D
  • Returns Vector3

  • Type parameters

    Parameters

    • dest: D

    Returns D

deserializeObject

divide

  • Parameters

    Returns this

equals

  • equals(vector: unknown, threshold?: number): vector is IVector3
  • Parameters

    • vector: unknown
    • Default value threshold: number = EPSILON

    Returns vector is IVector3

length

  • length(): number
  • Returns number

multiply

  • Parameters

    Returns this

negate

  • negate(): Vector3
  • negate<D>(dest: D): D
  • Returns Vector3

  • Type parameters

    Parameters

    • dest: D

    Returns D

normalize

  • normalize(): this
  • normalize<D>(dest: D): D
  • Returns this

  • Type parameters

    Parameters

    • dest: D

    Returns D

raw

  • Returns IVector3

reset

  • reset(): void
  • Returns void

scale

  • scale(value: number): this
  • scale<D>(value: number, dest: D): D
  • Parameters

    • value: number

    Returns this

  • Type parameters

    Parameters

    • value: number
    • dest: D

    Returns D

serializeObject

squaredLength

  • squaredLength(): number
  • Returns number

subtract

  • Parameters

    Returns this

toString

  • toString(): string
  • Returns string

Static cross

  • Parameters

    Returns Vector3

  • Type parameters

    Parameters

    Returns D

Static difference

  • Parameters

    Returns Vector3

  • Type parameters

    Parameters

    Returns D

Static direction

  • Parameters

    Returns Vector3

  • Type parameters

    Parameters

    Returns D

Static distance

  • Parameters

    Returns number

Static dot

  • Parameters

    Returns number

Static is

  • is(thing: unknown): thing is IVector3
  • Parameters

    • thing: unknown

    Returns thing is IVector3

Static mix

  • Parameters

    Returns Vector3

  • Type parameters

    Parameters

    Returns D

Static product

  • Parameters

    Returns Vector3

  • Type parameters

    Parameters

    Returns D

Static quotient

  • Parameters

    Returns Vector3

  • Type parameters

    Parameters

    Returns D

Static squaredDistance

  • Parameters

    Returns number

Static sum

  • Parameters

    Returns Vector3

  • Type parameters

    Parameters

    Returns D

Generated using TypeDoc