Class DynamicAbility

java.lang.Object
de.gurkenlabs.litiengine.abilities.Ability
de.gurkenlabs.litiengine.abilities.DynamicAbility
All Implemented Interfaces:
IRenderable
Direct Known Subclasses:
ScriptedAbility

public class DynamicAbility extends Ability
An Ability implementation configured programmatically with attributes and executed via callbacks.
  • Constructor Details

    • DynamicAbility

      public DynamicAbility(Creature executor, String name)
  • Method Details

    • setCastConsumer

      public void setCastConsumer(Consumer<AbilityExecution> castConsumer)
    • getCastConsumer

      public Consumer<AbilityExecution> getCastConsumer()
    • cast

      public AbilityExecution cast()
      Description copied from class: Ability
      Casts the ability by the temporal conditions of the specified game loop and the spatial circumstances of the specified environment. An ability execution will be taken out that start applying all the effects of this ability.
      Overrides:
      cast in class Ability
      Returns:
      An AbilityExecution object that wraps all information about this execution of the ability.