Basics

Guides

API Reference

Menu

Basics

Guides

API Reference

class: DoubleComponent

[17:7] extends: Component

Wraps an AussomDoubleComponent (concrete subclass of FXGL's abstract DoubleComponent). Exposes a double value backed by a JavaFX DoubleProperty plus standard Component lifecycle methods inherited from Component. Attach to an Entity via entity.addComponent.

Methods

  • DoubleComponent (double InitialValue = 0.0)

    Creates a new DoubleComponent with the given initial value.

    • @p InitialValue is the starting double (defaults to 0.0).
  • adopt (object Ajo)

    Wraps an existing AussomDoubleComponent AussomJavaObject.

  • getValue ()

    Returns the current double value.

  • setValue (double Val)

    Sets the double value.

    • @p Val is the new double.
    • @r this object
  • valueProperty ()

    Returns the underlying DoubleProperty for binding.

  • write (object BundleObj)

    Persists this component's value into a Bundle.

  • read (object BundleObj)

    Restores this component's value from a Bundle.