Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • Light

Index

Constructors

constructor

Properties

Private _color

_color: Uint8Array = new Uint8Array([255, 255, 255, 255])

Private _index

_index: number = -1

Private _on

_on: boolean = false

Private _position

_position: Vector3 = new Vector3(0, 0, 0)

Private _positionsWritten

_positionsWritten: boolean = false

Private _range

_range: number = 2000

Private _rangeWritten

_rangeWritten: boolean = false

engine

engine: Engine

Accessors

position

range

  • get range(): number
  • set range(value: number): void

Methods

move

  • move(x: number, y: number, z: number): void
  • Move light

    Parameters

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

    Returns void

off

  • off(): void
  • Turn off light. Remove this light from drawing process.

    Returns void

on

  • on(): void

setColorRGBA

  • setColorRGBA(r: number, g: number, b: number, a: number): void
  • Setting color of light

    Parameters

    • r: number

      red value from 0 to 255.

    • g: number

      green value from 0 to 255.

    • b: number

      blue value from 0 to 255.

    • a: number

      alpha value from 0 to 255.

    Returns void

setPosition

  • setPosition(vector: Vector3): void
  • setPosition(array: number[]): void
  • setPosition(x: number, y: number, z: number): void
  • Sets position for object. Using another vector.

    Parameters

    Returns void

  • Sets position for object. Using array of coordinates.

    Parameters

    • array: number[]

    Returns void

  • Sets position for object. Using coordinates.

    Parameters

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

    Returns void

setRange

  • setRange(value: number): void

Generated using TypeDoc