Class AbilityEffect
java.lang.Object
de.gurkenlabs.litiengine.abilities.effects.Effect
de.gurkenlabs.litiengine.abilities.effects.AbilityEffect
- All Implemented Interfaces:
IUpdateable
The AbilityEffect class is an abstract class that represents an effect associated with a specific ability. It extends the Effect class and is
used to apply effects that are tied to a particular ability.
This class provides a way to manage and access the ability that triggers the effect, allowing for the integration of ability-specific attributes such as the executor and duration.
-
Nested Class Summary
Nested classes/interfaces inherited from class Effect
Effect.EffectAppliedListener, Effect.EffectCeasedListener -
Field Summary
Fields inherited from interface IUpdateable
DEFAULT_UPDATE_PRIORITY -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbilityEffect(TargetingStrategy targetingStrategy, Ability ability) Constructs a newAbilityEffectwith the specified targeting strategy and ability. -
Method Summary
Modifier and TypeMethodDescriptionGets the ability associated with this effect.Methods inherited from class Effect
apply, apply, cease, cease, getActiveAppliances, getDelay, getDuration, getExecutingEntity, getFollowUpEffects, getTargetingStrategy, getTotalDuration, hasEnded, isActive, onEffectApplied, onEffectCeased, removeEffectAppliedListener, removeEffectCeasedListener, setDelay, setDuration, updateMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface IUpdateable
getUpdatePriority
-
Constructor Details
-
AbilityEffect
Constructs a new
AbilityEffectwith the specified targeting strategy and ability.The effect will inherit the executor and duration attributes from the provided ability.
- Parameters:
targetingStrategy- The strategy used to select the targets for this effect.ability- The ability associated with this effect, providing information such as the executor and duration.
-
-
Method Details
-
getAbility
Gets the ability associated with this effect.- Returns:
- The ability associated with this effect.
-