Lens Scripting API

    Billboard allows an object to rotate to face the camera.

    Hierarchy (View Summary, Expand)

    Index

    Constructors

    Properties

    api: Record<string, any>

    Generic object accessible by other instances of ScriptComponent. Use this object to store references to properties and methods that need to be accessible from other ScriptComponents.

    duration: number = 0.033

    This property no longer changes the speed of the follow rotation. Use _axisEasing instead.

    enabled: boolean

    If disabled, the Component will stop enacting its behavior.

    name: string
    sceneObject: SceneObject

    The scene object this component is on.

    uniqueIdentifier: string
    updatePriority: number

    Accessors

    • get axisBufferDegrees(): vec3

      Returns vec3

      the vector defining the buffer for each axis.

    • set axisBufferDegrees(bufferDegrees: vec3): void

      Parameters

      • bufferDegrees: vec3

        the vector defining the buffer for each axis.

      Returns void

    • get axisEasing(): vec3

      Returns vec3

      the vector defining the easing for each axis.

    • set axisEasing(easing: vec3): void

      Parameters

      • easing: vec3

        the vector defining the easing for each axis. For instant follow, use easing = (1,1,1).

      Returns void

    • get xAxisEnabled(): boolean

      Returns boolean

      if the SceneObject billboards about the x-axis.

    • set xAxisEnabled(enabled: boolean): void

      Parameters

      • enabled: boolean

        defines if the SceneObject billboards about the x-axis.

      Returns void

    • get yAxisEnabled(): boolean

      Returns boolean

      if the SceneObject billboards about the y-axis.

    • set yAxisEnabled(enabled: boolean): void

      Parameters

      • enabled: boolean

        defines if the SceneObject billboards about the y-axis.

      Returns void

    • get zAxisEnabled(): boolean

      Returns boolean

      if the SceneObject billboards about the z-axis.

    • set zAxisEnabled(enabled: boolean): void

      Parameters

      • enabled: boolean

        defines if the SceneObject billboards about the z-axis.

      Returns void

    Methods

    • Returns true if the object matches or derives from the passed in type.

      Parameters

      • type: string

      Returns boolean

    • Returns void

    • Immediately resets the SceneObject to the rotation according to inputs regardless of easing.

      Returns void

    MMNEPVFCICPMFPCPTTAAATR