Basics

Guides

API Reference

Menu

Basics

Guides

API Reference

class: FadeAnimationBuilder

[18:7] extends: AnimationBuilder

Wraps FXGL's AnimationBuilder.FadeAnimationBuilder, the subbuilder returned by AnimationBuilder.fade(entities) / fadeIn(entities) / fadeOut(entities). Use from / to to set the opacity endpoints, then build or buildAndPlay. fadeIn already configures from(0.0).to(1.0) and fadeOut already configures from(1.0).to(0.0); call from / to only when overriding those defaults.

Methods

  • FadeAnimationBuilder ()

    Empty default constructor; populated by adopt.

  • adopt (object Ajo)

    Wraps an existing FadeAnimationBuilder AussomJavaObject.

    • @p Ajo is an AussomJavaObject around the FXGL subbuilder.
    • @r A new wrapper.
  • from (double Start)

    Sets the start opacity (0.0 - 1.0).

    • @p Start is the start opacity.
    • @r this object
  • to (double End)

    Sets the end opacity (0.0 - 1.0).

    • @p End is the end opacity.
    • @r this object
  • build ()

    Builds the Animation without playing it.

    • @r An Animation wrapper.
  • buildAndPlay ()

    Builds the Animation and starts it in the scene this builder was created with.

    • @r this object
  • buildAndPlayIn (object SceneObj)

    Builds the Animation and starts it in the supplied scene.

    • @p SceneObj is a Scene wrapper.
    • @r this object