Class ModifyScalePower

java.lang.Object
io.github.apace100.apoli.power.Power
dev.jaxydog.astral.content.power.AstralPower
dev.jaxydog.astral.content.power.custom.ModifyScalePower

public class ModifyScalePower extends AstralPower
A power that applies modifiers to various scale types.
Since:
1.7.0
  • Field Summary

    Fields inherited from class io.github.apace100.apoli.power.Power

    conditions, entity, type
  • Constructor Summary

    Constructors
    Constructor
    Description
    ModifyScalePower(io.github.apace100.apoli.power.PowerType<?> type, net.minecraft.entity.LivingEntity entity, Collection<virtuoel.pehkui.api.ScaleType> scaleTypes, int transition, int tickRate, boolean resetOnLoss)
    Creates a new modify scale power.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addModifier(io.github.apace100.apoli.util.modifier.Modifier modifier)
    Adds a scale modifier to the power.
    Returns the power factory associated with this power type.
    void
     
    void
     

    Methods inherited from class io.github.apace100.apoli.power.Power

    addCondition, createSimpleFactory, fromTag, getType, isActive, onAdded, onGained, onLost, onRespawn, setTicking, setTicking, shouldTick, shouldTickWhenInactive, toTag

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ModifyScalePower

      public ModifyScalePower(io.github.apace100.apoli.power.PowerType<?> type, net.minecraft.entity.LivingEntity entity, Collection<virtuoel.pehkui.api.ScaleType> scaleTypes, int transition, int tickRate, boolean resetOnLoss)
      Creates a new modify scale power.
      Parameters:
      type - The power's type.
      entity - The holding entity.
      scaleTypes - A collection of scale types.
      transition - The tick duration of the transition period.
      tickRate - The tick interval at which to update.
      resetOnLoss - Whether scales are reset when the power is lost.
      Since:
      1.7.0
  • Method Details

    • getFactory

      public static AstralPowerFactory<ModifyScalePower> getFactory()
      Returns the power factory associated with this power type.
      Returns:
      The power factory associated with this power type.
      Since:
      1.7.0
    • addModifier

      public void addModifier(io.github.apace100.apoli.util.modifier.Modifier modifier)
      Adds a scale modifier to the power.
      Parameters:
      modifier - A scale modifier.
      Since:
      1.7.0
    • tick

      public void tick()
      Overrides:
      tick in class io.github.apace100.apoli.power.Power
    • onRemoved

      public void onRemoved()
      Overrides:
      onRemoved in class io.github.apace100.apoli.power.Power