Class DecayEffect
java.lang.Object
net.minecraft.world.effect.MobEffect
etithespirit.orimod.util.RichEffect
etithespirit.orimod.common.potion.DecayEffect
- All Implemented Interfaces:
net.minecraftforge.common.extensions.IForgeMobEffect
The status effect that occurs when someone is decaying.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final net.minecraft.resources.ResourceLocation
The icon of the Decay effect.static final int
The longest delay in decay ticks measured in real ticks.static final int
The max effective level of Decay.static final int
The damage done per decay tick at level MAX_AMP-1.static final int
The damage done per decay tick at level 0.static final int
The shortest delay in decay ticks measured in real ticks. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
applyEffectTick
(net.minecraft.world.entity.LivingEntity entity, int amplifier) net.minecraft.world.effect.MobEffectCategory
Returns the default type for this effect.int
getColor()
Returns the default color for this effect.net.minecraft.resources.ResourceLocation
Returns theResourceLocation
representing the image to be used as this effect's icon.int
int
boolean
isDurationEffectTick
(int duration, int amplifier) Methods inherited from class etithespirit.orimod.util.RichEffect
getEffectRendererInternal
Methods inherited from class net.minecraft.world.effect.MobEffect
addAttributeModifier, addAttributeModifiers, applyInstantenousEffect, byId, createFactorData, getAttributeModifiers, getAttributeModifierValue, getDescriptionId, getDisplayName, getId, getIdFromNullable, getOrCreateDescriptionId, initializeClient, isBeneficial, isInstantenous, removeAttributeModifiers, setFactorDataFactory
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraftforge.common.extensions.IForgeMobEffect
getCurativeItems, getSortOrder
-
Field Details
-
DECAY_ICON
public static final net.minecraft.resources.ResourceLocation DECAY_ICONThe icon of the Decay effect. -
MAX_AMP
public static final int MAX_AMPThe max effective level of Decay.- See Also:
-
MIN_DAMAGE
public static final int MIN_DAMAGEThe damage done per decay tick at level 0.- See Also:
-
MAX_DAMAGE
public static final int MAX_DAMAGEThe damage done per decay tick at level MAX_AMP-1.- See Also:
-
LONGEST_DELAY_TICKS
public static final int LONGEST_DELAY_TICKSThe longest delay in decay ticks measured in real ticks. This occurs at level 0.- See Also:
-
SHORTEST_DELAY_TICKS
public static final int SHORTEST_DELAY_TICKSThe shortest delay in decay ticks measured in real ticks. This occurs at level MAX_AMP-1.- See Also:
-
-
Constructor Details
-
DecayEffect
public DecayEffect()
-
-
Method Details
-
getCategory
public net.minecraft.world.effect.MobEffectCategory getCategory()Description copied from class:RichEffect
Returns the default type for this effect. This value is cached and this method will only be called once.- Specified by:
getCategory
in classRichEffect
- Returns:
- The type of effect.
-
getTextMainColor
public int getTextMainColor()- Overrides:
getTextMainColor
in classRichEffect
- Returns:
- The color of the text foreground.
-
getTextShadowColor
public int getTextShadowColor()- Overrides:
getTextShadowColor
in classRichEffect
- Returns:
- The color of the text shadow.
-
getColor
public int getColor()Description copied from class:RichEffect
Returns the default color for this effect. This value is cached and this method will only be called once.- Specified by:
getColor
in classRichEffect
- Returns:
- The custom color. 0x00RRGGBB
-
getCustomIcon
public net.minecraft.resources.ResourceLocation getCustomIcon()Description copied from class:RichEffect
Returns theResourceLocation
representing the image to be used as this effect's icon. It may return null if a default icon is used.- Specified by:
getCustomIcon
in classRichEffect
- Returns:
- The custom icon, or null to use a vanilla icon as defined by
MobEffect
.
-
applyEffectTick
public void applyEffectTick(net.minecraft.world.entity.LivingEntity entity, int amplifier) - Overrides:
applyEffectTick
in classnet.minecraft.world.effect.MobEffect
-
isDurationEffectTick
public boolean isDurationEffectTick(int duration, int amplifier) - Overrides:
isDurationEffectTick
in classnet.minecraft.world.effect.MobEffect
-