Options
All
  • Public
  • Public/Protected
  • All
Menu

Class SetValueAction

This defines an action responsible to set a property of the target to a desired value once triggered.

see

https://doc.babylonjs.com/how_to/how_to_use_actions

Hierarchy

Implements

Index

Constructors

constructor

  • new SetValueAction(triggerOptions: any, target: any, propertyPath: string, value: any, condition?: Condition): SetValueAction
  • Instantiate the action

    Parameters

    • triggerOptions: any

      defines the trigger options

    • target: any

      defines the object containing the property

    • propertyPath: string

      defines the path of the property to set in the target

    • value: any

      defines the value to set in the property

    • Optional condition: Condition

      defines the trigger related conditions

    Returns SetValueAction

Properties

onBeforeExecuteObservableSearch playground for onBeforeExecuteObservable

onBeforeExecuteObservable: Observable<Action>

An event triggered prior to action being executed.

propertyPathSearch playground for propertyPath

propertyPath: string

The path of the property to set in the target.

triggerSearch playground for trigger

trigger: number

Trigger for the action

triggerOptionsSearch playground for triggerOptions

triggerOptions: any

the trigger, with or without parameters, for the action

valueSearch playground for value

value: any

The value to set in the property

Methods

executeSearch playground for execute

  • execute(): void
  • Execute the action and set the targeted property to the desired value.

    Returns void

getTriggerParameterSearch playground for getTriggerParameter

  • getTriggerParameter(): any

serializeSearch playground for serialize

  • serialize(parent: any): any
  • Serializes the actions and its related information.

    Parameters

    • parent: any

      defines the object to serialize in

    Returns any

    the serialized object

setTriggerParameterSearch playground for setTriggerParameter

  • setTriggerParameter(value: any): void
  • Sets the trigger parameter

    Parameters

    • value: any

      defines the new trigger parameter

    Returns void

skipToNextActiveActionSearch playground for skipToNextActiveAction

  • skipToNextActiveAction(): void

thenSearch playground for then

Legend

  • Constructor
  • Property
  • Method
  • Property
  • Method
  • Inherited property
  • Inherited method
  • Static property
  • Static method