Class AbstractBurningElementalReaction
java.lang.Object
io.github.xrickastley.sevenelements.element.reaction.ElementalReaction
io.github.xrickastley.sevenelements.element.reaction.AbstractBurningElementalReaction
- Direct Known Subclasses:
BurningElementalReaction,QuickenBurningElementalReaction
public abstract sealed class AbstractBurningElementalReaction
extends ElementalReaction
permits BurningElementalReaction, QuickenBurningElementalReaction
-
Nested Class Summary
Nested classes/interfaces inherited from class io.github.xrickastley.sevenelements.element.reaction.ElementalReaction
ElementalReaction.Settings -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final InternalCooldownTypeprivate static final Supplier<Set<ElementalReaction>> Fields inherited from class io.github.xrickastley.sevenelements.element.reaction.ElementalReaction
applyResultAsAura, auraElement, endsReactionTrigger, id, name, preventsPriorityUpgrade, preventsReactionsAfter, reactionCoefficient, reactionDisplayOrder, reversable, text, triggeringElement -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanisTriggerable(LivingEntity entity) static booleanmixin$allowDendroPassthrough(boolean original, ElementComponent component, ElementalApplication application) static Optional<ElementalReaction> mixin$changeReaction(Optional<ElementalReaction> original, ElementComponent component, ElementalApplication application) static voidmixin$forceReapplyDendroWhenBurning(ElementComponent component, ElementalApplication application) Reapplies the Dendro element when the only "highest priority" element is Burning.static booleanmixin$onlyAllowPyroReactions(boolean original, ElementComponent component, ElementalReaction reaction) static voidmixin$reduceQuickenGauge(ElementalApplication application) static voidmixin$tick(LivingEntity entity) protected voidonReaction(LivingEntity entity, ElementalApplication auraElement, ElementalApplication triggeringElement, double reducedGauge, @Nullable LivingEntity origin) The function to execute after the Elemental Reaction has been triggered.Methods inherited from class io.github.xrickastley.sevenelements.element.reaction.ElementalReaction
displayReaction, getAuraElement, getAuraElementPriority, getElementPair, getEntitiesInAoE, getEntitiesInAoE, getHighestElementPriority, getId, getPriority, getPriority, getReactionDamage, getReactionDamage, getReactionDamage, getReactionDamage, getReactionDisplayOrder, getText, getTriggeringElement, getTriggeringElementPriority, hasAnyElement, hasAnyElement, hasElement, idEquals, isTriggerable, onTrigger, preventsReaction, preventsReaction, shouldApplyResultAsAura, shouldEndReactionTrigger, shouldPreventPriorityUpgrade, trigger, trigger
-
Field Details
-
BURNING_PYRO_ICD
-
REACTIONS
-
-
Constructor Details
-
AbstractBurningElementalReaction
AbstractBurningElementalReaction(ElementalReaction.Settings settings)
-
-
Method Details
-
isTriggerable
- Overrides:
isTriggerablein classElementalReaction
-
onReaction
protected void onReaction(LivingEntity entity, ElementalApplication auraElement, ElementalApplication triggeringElement, double reducedGauge, @Nullable @Nullable LivingEntity origin) Description copied from class:ElementalReactionThe function to execute after the Elemental Reaction has been triggered. This function is executed after both elements have reacted and have been reduced.- Specified by:
onReactionin classElementalReaction- Parameters:
entity- TheLivingEntitythis Elemental Reaction was triggered on.auraElement- The aura element that triggered this reaction.triggeringElement- The triggering element that reacted with the aura element.reducedGauge- The gauge units reduced from both Elements. This will always beMath.min(auraElementGU, triggeringElementGU * reactionCoefficient)origin- TheLivingEntitythat triggered this Elemental Reaction.
-
mixin$tick
-
mixin$forceReapplyDendroWhenBurning
@Inject(method="Lio/github/xrickastley/sevenelements/component/ElementComponentImpl;attemptReapply(Lio/github/xrickastley/sevenelements/element/ElementalApplication;)Z", at=@At(value="IF",ordinal=2), directive="INJECT_AS_ELSE") public static void mixin$forceReapplyDendroWhenBurning(@Local(self=true) ElementComponent component, @Local(argsOnly=true) ElementalApplication application) Reapplies the Dendro element when the only "highest priority" element is Burning.
This method will overwrite the current Dendro aura with the provided Elemental Application, as specified by the "Burning Refresh" mechanic by Elemental Gauge Theory > Advanced Mechanics > Burning.
If the provided application is not the Dendro element, it is ignored.- Parameters:
application- TheElementalApplicationto reapply.
-
mixin$onlyAllowPyroReactions
@ModifyExpressionValue(method="Lio/github/xrickastley/sevenelements/component/ElementComponentImpl;triggerReactions(Lio/github/xrickastley/sevenelements/element/ElementalApplication;Lnet/minecraft/entity/LivingEntity;)Ljava/util/Set;", at=@At(value="INVOKE",target="Ljava/util/stream/Stream;noneMatch(Ljava/util/function/Predicate;)Z")) public static boolean mixin$onlyAllowPyroReactions(boolean original, @Local(self=true) ElementComponent component, @Local ElementalReaction reaction) -
mixin$allowDendroPassthrough
@ModifyExpressionValue(method="Lio/github/xrickastley/sevenelements/component/ElementComponentImpl;triggerReactions(Lio/github/xrickastley/sevenelements/element/ElementalApplication;Lnet/minecraft/entity/LivingEntity;)Ljava/util/Set;", at=@At(value="CONSTANT_ACCESS",target="hasHigherPriority;Z")) public static boolean mixin$allowDendroPassthrough(boolean original, @Local ElementComponent component, @Local ElementalApplication application) -
mixin$reduceQuickenGauge
-
mixin$changeReaction
@ModifyVariable(method="Lio/github/xrickastley/sevenelements/component/ElementComponentImpl;triggerReactions(Lio/github/xrickastley/sevenelements/element/ElementalApplication;Lnet/minecraft/entity/LivingEntity;)Ljava/util/Set;", at=@At(value="STORE",ordinal=3,shift=AFTER)) public static Optional<ElementalReaction> mixin$changeReaction(Optional<ElementalReaction> original, @Local(self=true) ElementComponent component, @Local(argsOnly=true) ElementalApplication application)
-