omega-game-engine
    Preparing search index...

    Class Vector3

    A class representing a 3D vector, backed by a gl-matrix vec3. *

    Hierarchy (View Summary)

    Indexable

    • [key: string]: any
    Index

    Constructors

    • Creates an instance of Vector3. *

      Parameters

      • Optionalx: number = 0

        The x-component. *

      • Optionaly: number = 0

        The y-component. *

      • Optionalz: number = 0

        The z-component.

      Returns Vector3

    Properties

    _className: string = "Vector3"
    _serializationIgnoreKeys: string[]
    _uuid: string
    _vec: vec3

    The internal gl-matrix vector. * *

    name: string = ''

    Accessors

    • get vector(): vec3

      Gets the internal gl-matrix vector. *

      Returns vec3

      • The internal vector instance.
    • get x(): number

      Gets the x-component of the vector. *

      Returns number

    • set x(value: number): void

      Sets the x-component of the vector. *

      Parameters

      • value: number

        The new value for the x-component.

      Returns void

    • get y(): number

      Gets the y-component of the vector. *

      Returns number

    • set y(value: number): void

      Sets the y-component of the vector. *

      Parameters

      • value: number

        The new value for the y-component.

      Returns void

    • get z(): number

      Gets the z-component of the vector. *

      Returns number

    • set z(value: number): void

      Sets the z-component of the vector. *

      Parameters

      • value: number

        The new value for the z-component.

      Returns void

    • get className(): string

      Returns string

    Methods

    • Sets the components of the vector. * *

      Parameters

      • Optionalx: number = 0

        The new x-component. *

      • Optionaly: number = 0

        The new y-component. *

      • Optionalz: number = 0

        The new z-component. *

      Returns void