Class MobEffect

java.lang.Object
net.minecraft.world.effect.MobEffect
All Implemented Interfaces:
IForgeMobEffect
Direct Known Subclasses:
AbsoptionMobEffect, AttackDamageMobEffect, HealthBoostMobEffect, InstantenousMobEffect

public class MobEffect extends Object implements IForgeMobEffect
  • Field Details

  • Constructor Details

  • Method Details

    • byId

      @Nullable public static MobEffect byId(int p_19454_)
    • getId

      public static int getId(MobEffect p_19460_)
    • getIdFromNullable

      public static int getIdFromNullable(@Nullable MobEffect p_216883_)
    • createFactorData

      public Optional<MobEffectInstance.FactorData> createFactorData()
    • applyEffectTick

      public void applyEffectTick(LivingEntity p_19467_, int p_19468_)
    • applyInstantenousEffect

      public void applyInstantenousEffect(@Nullable Entity p_19462_, @Nullable Entity p_19463_, LivingEntity p_19464_, int p_19465_, double p_19466_)
    • isDurationEffectTick

      public boolean isDurationEffectTick(int p_19455_, int p_19456_)
    • isInstantenous

      public boolean isInstantenous()
    • getOrCreateDescriptionId

      protected String getOrCreateDescriptionId()
    • getDescriptionId

      public String getDescriptionId()
    • getDisplayName

      public Component getDisplayName()
    • getCategory

      public MobEffectCategory getCategory()
    • getColor

      public int getColor()
    • addAttributeModifier

      public MobEffect addAttributeModifier(Attribute p_19473_, String p_19474_, double p_19475_, AttributeModifier.Operation p_19476_)
    • setFactorDataFactory

      public MobEffect setFactorDataFactory(Supplier<MobEffectInstance.FactorData> p_216880_)
    • getAttributeModifiers

      public Map<Attribute,AttributeModifier> getAttributeModifiers()
    • removeAttributeModifiers

      public void removeAttributeModifiers(LivingEntity p_19469_, AttributeMap p_19470_, int p_19471_)
    • addAttributeModifiers

      public void addAttributeModifiers(LivingEntity p_19478_, AttributeMap p_19479_, int p_19480_)
    • getAttributeModifierValue

      public double getAttributeModifierValue(int p_19457_, AttributeModifier p_19458_)
    • isBeneficial

      public boolean isBeneficial()
    • getEffectRendererInternal

      public Object getEffectRendererInternal()
    • initClient

      private void initClient()
    • initializeClient

      public void initializeClient(Consumer<IClientMobEffectExtensions> consumer)