Color over lifetime module

ColorOverLifetimeModule

2024.4.2

yisky

Hierarchy (view full)

Constructors

Properties

_enable: boolean = false
color: MinMaxGradient = ...

The gradient that controls the particle colors.

ColorOverLifetimeModule

Accessors

  • get enable(): boolean
  • Specifies whether enable the module.

    Returns boolean

    ParticleModule

  • set enable(value): void
  • Specifies whether enable the module.

    Parameters

    • value: boolean

    Returns void

    ParticleModule

Methods

  • Protected

    Enable callback

    Returns void

    ParticleModule

  • Protected

    Serialize

    Parameters

    • meta: {
          [key: string]: any;
      }
      • [key: string]: any

    Returns void

    ColorOverLifetimeModule

  • Emit event

    Parameters

    • event: {
          type: string;
          [key: string]: any;
      }
      • [key: string]: any
      • type: string

    Returns void

    EventDispatcher

  • Deserialze

    Parameters

    • json: {
          [key: string]: any;
      }
      • [key: string]: any

    Returns void

    ColorOverLifetimeModule

  • Unsubscribe a event, if the callback param is not defined, all subscribers of this type will be removed.

    Parameters

    • type: string
    • Optionalcallback: SubscriberCallbackFn

      subscriber callback

    Returns void

    EventDispatcher

  • Subscribe a event

    Parameters

    • type: string

      event type

    • callback: SubscriberCallbackFn

      callback functions

    • Optionaloptions: {
          priority?: Priority;
          target?: any;
      }

      options

      • Optionalpriority?: Priority
      • Optionaltarget?: any

    Returns void

    EventDispatcher

  • Subscribe a event, just emit once

    Parameters

    • type: string
    • callback: SubscriberCallbackFn

      subscriber callback

    • Optionaloptions: {
          priority?: Priority;
          target?: any;
      }
      • Optionalpriority?: Priority
      • Optionaltarget?: any

    Returns void

    EventDispatcher

  • Serialize

    Returns {
        [key: string]: any;
    }

    • [key: string]: any

    ParticleModule