API

Class InterpolateValueAction

This defines an action responsible to change the value of a property by interpolating between its current value and the newly set one once triggered.

Hierarchy (View Summary)

  • Action
    • InterpolateValueAction
Index
  • Instantiate the action

    Parameters

    • triggerOptions: any

      defines the trigger options

    • target: any

      defines the object containing the value to interpolate

    • propertyPath: string

      defines the path to the property in the target object

    • value: any

      defines the target value at the end of the interpolation

    • duration: number = 1000

      defines the time it will take for the property to interpolate to the value.

    • Optionalcondition: Condition

      defines the trigger related conditions

    • OptionalstopOtherAnimations: boolean

      defines if the other scene animations should be stopped when the action has been triggered

    • OptionalonInterpolationDone: () => void

      defines a callback raised once the interpolation animation has been done

    Returns InterpolateValueAction

duration: number = 1000

Defines the time it will take for the property to interpolate to the value.

onBeforeExecuteObservable: Observable<Action> = ...

An event triggered prior to action being executed.

onInterpolationDone?: () => void

Defines a callback raised once the interpolation animation has been done.

onInterpolationDoneObservable: Observable<InterpolateValueAction> = ...

Observable triggered once the interpolation animation has been done.

propertyPath: string

Defines the path of the property where the value should be interpolated

stopOtherAnimations?: boolean

Defines if the other scene animations should be stopped when the action has been triggered

trigger: number

Trigger for the action

triggerOptions: any

the trigger, with or without parameters, for the action

value: any

Defines the target value at the end of the interpolation.