Options
All
  • Public
  • Public/Protected
  • All
Menu

This defines an action responsible to start an animation once triggered.

see

https://doc.babylonjs.com/features/featuresDeepDive/events/actions

Hierarchy

Index

Constructors

  • new PlayAnimationAction(triggerOptions: any, target: any, from: number, to: number, loop?: boolean, condition?: Condition): PlayAnimationAction
  • Instantiate the action

    Parameters

    • triggerOptions: any

      defines the trigger options

    • target: any

      defines the target animation or animation name

    • from: number

      defines from where the animation should start (animation frame)

    • to: number

      defines where the animation should stop (animation frame)

    • Optional loop: boolean

      defines if the animation should loop or stop after the first play

    • Optional condition: Condition

      defines the trigger related conditions

    Returns PlayAnimationAction

Properties

from: number

Where the animation should start (animation frame)

loop?: boolean

Define if the animation should loop or stop after the first play.

onBeforeExecuteObservable: Observable<Action>

An event triggered prior to action being executed.

to: number

Where the animation should stop (animation frame)

trigger: number

Trigger for the action

triggerOptions: any

the trigger, with or without parameters, for the action

Methods

  • execute(): void
  • Execute the action and play the animation.

    Returns void

  • getTriggerParameter(): any
  • Gets the trigger parameter

    Returns any

    the trigger parameter

  • 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

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

    Parameters

    • value: any

      defines the new trigger parameter

    Returns void

  • skipToNextActiveAction(): void

Legend

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

Settings

Theme