Uses of Class
net.minecraft.world.effect.MobEffectInstance
Packages that use MobEffectInstance
Package
Description
Events fired only on the client-side, chiefly related to rendering and user interfaces (screens and input).
-
Uses of MobEffectInstance in net.minecraft.advancements.critereon
Methods in net.minecraft.advancements.critereon with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionboolean
MobEffectsPredicate.MobEffectInstancePredicate.matches
(MobEffectInstance p_56578_) Method parameters in net.minecraft.advancements.critereon with type arguments of type MobEffectInstanceModifier and TypeMethodDescriptionboolean
MobEffectsPredicate.matches
(Map<Holder<MobEffect>, MobEffectInstance> p_56562_) -
Uses of MobEffectInstance in net.minecraft.client.gui.screens.inventory
Methods in net.minecraft.client.gui.screens.inventory with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionprivate Component
EffectsInInventory.getEffectName
(MobEffectInstance p_376252_) Method parameters in net.minecraft.client.gui.screens.inventory with type arguments of type MobEffectInstanceModifier and TypeMethodDescriptionprivate void
EffectsInInventory.renderBackgrounds
(GuiGraphics p_376873_, int p_376485_, int p_376217_, Iterable<MobEffectInstance> p_376444_, boolean p_376129_) private void
EffectsInInventory.renderIcons
(GuiGraphics p_376734_, int p_376350_, int p_376678_, Iterable<MobEffectInstance> p_376215_, boolean p_376312_) private void
EffectsInInventory.renderLabels
(GuiGraphics p_376227_, int p_376372_, int p_376395_, Iterable<MobEffectInstance> p_376910_) -
Uses of MobEffectInstance in net.minecraft.client.renderer
Methods in net.minecraft.client.renderer with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionfloat
FogRenderer.DarknessFogFunction.getModifiedVoidDarkness
(LivingEntity p_234189_, MobEffectInstance p_234190_, float p_234191_, float p_234192_) default float
FogRenderer.MobEffectFogFunction.getModifiedVoidDarkness
(LivingEntity p_234208_, MobEffectInstance p_234209_, float p_234210_, float p_234211_) void
FogRenderer.BlindnessFogFunction.setupFog
(FogRenderer.FogData p_234181_, LivingEntity p_234182_, MobEffectInstance p_234183_, float p_234184_, float p_234185_) void
FogRenderer.DarknessFogFunction.setupFog
(FogRenderer.FogData p_234194_, LivingEntity p_234195_, MobEffectInstance p_234196_, float p_234197_, float p_234198_) void
FogRenderer.MobEffectFogFunction.setupFog
(FogRenderer.FogData p_234212_, LivingEntity p_234213_, MobEffectInstance p_234214_, float p_234215_, float p_234216_) -
Uses of MobEffectInstance in net.minecraft.network.protocol.game
Constructors in net.minecraft.network.protocol.game with parameters of type MobEffectInstanceModifierConstructorDescriptionClientboundUpdateMobEffectPacket
(int p_133611_, MobEffectInstance p_133612_, boolean p_316376_) -
Uses of MobEffectInstance in net.minecraft.server.level
Methods in net.minecraft.server.level with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionprotected void
ServerPlayer.onEffectAdded
(MobEffectInstance p_143393_, Entity p_143394_) protected void
ServerPlayer.onEffectUpdated
(MobEffectInstance p_143396_, boolean p_143397_, Entity p_143398_) Method parameters in net.minecraft.server.level with type arguments of type MobEffectInstanceModifier and TypeMethodDescriptionprotected void
ServerPlayer.onEffectsRemoved
(Collection<MobEffectInstance> p_366811_) -
Uses of MobEffectInstance in net.minecraft.world.effect
Fields in net.minecraft.world.effect declared as MobEffectInstanceFields in net.minecraft.world.effect with type parameters of type MobEffectInstanceModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec
<MobEffectInstance> MobEffectInstance.CODEC
private final Function
<MobEffectInstance, ParticleOptions> MobEffect.particleFactory
static final StreamCodec
<RegistryFriendlyByteBuf, MobEffectInstance> MobEffectInstance.STREAM_CODEC
Methods in net.minecraft.world.effect that return MobEffectInstanceMethods in net.minecraft.world.effect with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionstatic List
<ServerPlayer> MobEffectUtil.addEffectToPlayersAround
(ServerLevel p_216947_, Entity p_216948_, Vec3 p_216949_, double p_216950_, MobEffectInstance p_216951_, int p_216952_) int
MobEffectInstance.compareTo
(MobEffectInstance p_19566_) void
MobEffectInstance.copyBlendState
(MobEffectInstance p_316485_) MobEffect.createParticleOptions
(MobEffectInstance p_333815_) static Component
MobEffectUtil.formatDuration
(MobEffectInstance p_268116_, float p_268280_, float p_314720_) private static boolean
MobEffectInstance.BlendState.hasEffect
(MobEffectInstance p_393561_) private boolean
MobEffectInstance.isShorterDurationThan
(MobEffectInstance p_268133_) (package private) void
MobEffectInstance.setDetailsFrom
(MobEffectInstance p_19549_) void
MobEffectInstance.BlendState.setImmediate
(MobEffectInstance p_316328_) void
MobEffectInstance.BlendState.tick
(MobEffectInstance p_316550_) boolean
MobEffectInstance.update
(MobEffectInstance p_19559_) Constructors in net.minecraft.world.effect with parameters of type MobEffectInstanceModifierConstructorDescriptionMobEffectInstance
(Holder<MobEffect> p_316176_, int p_19529_, int p_19530_, boolean p_19531_, boolean p_19532_, boolean p_19533_, MobEffectInstance p_316863_) MobEffectInstance
(MobEffectInstance p_19543_) Constructor parameters in net.minecraft.world.effect with type arguments of type MobEffectInstanceModifierConstructorDescriptionprotected
MobEffect
(MobEffectCategory category, int color, Function<MobEffectInstance, ParticleOptions> particleFactory) Neo: Constructor that can take in the particle factory as a function of theMobEffectInstance
. -
Uses of MobEffectInstance in net.minecraft.world.entity
Fields in net.minecraft.world.entity with type parameters of type MobEffectInstanceModifier and TypeFieldDescriptionprivate final Map
<Holder<MobEffect>, MobEffectInstance> LivingEntity.activeEffects
Methods in net.minecraft.world.entity that return MobEffectInstanceModifier and TypeMethodDescriptionfinal MobEffectInstance
LivingEntity.removeEffectNoUpdate
(Holder<MobEffect> p_316233_) Methods in net.minecraft.world.entity that return types with arguments of type MobEffectInstanceModifier and TypeMethodDescriptionLivingEntity.getActiveEffects()
LivingEntity.getActiveEffectsMap()
Methods in net.minecraft.world.entity with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionvoid
AreaEffectCloud.addEffect
(MobEffectInstance p_19717_) final boolean
LivingEntity.addEffect
(MobEffectInstance p_21165_) boolean
LivingEntity.addEffect
(MobEffectInstance p_147208_, Entity p_147209_) boolean
LivingEntity.canBeAffected
(MobEffectInstance p_21197_) Deprecated.void
LivingEntity.forceAddEffect
(MobEffectInstance p_147216_, Entity p_147217_) protected void
LivingEntity.onEffectAdded
(MobEffectInstance p_147190_, Entity p_147191_) protected void
LivingEntity.onEffectUpdated
(MobEffectInstance p_147192_, boolean p_147193_, Entity p_147194_) void
LivingEntity.sendEffectToPassengers
(MobEffectInstance p_289695_) Method parameters in net.minecraft.world.entity with type arguments of type MobEffectInstanceModifier and TypeMethodDescriptionstatic boolean
LivingEntity.areAllEffectsAmbient
(Collection<MobEffectInstance> p_21180_) protected void
LivingEntity.onEffectsRemoved
(Collection<MobEffectInstance> p_366501_) -
Uses of MobEffectInstance in net.minecraft.world.entity.boss.enderdragon
Methods in net.minecraft.world.entity.boss.enderdragon with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionboolean
EnderDragon.addEffect
(MobEffectInstance p_182394_, Entity p_182395_) -
Uses of MobEffectInstance in net.minecraft.world.entity.boss.wither
Methods in net.minecraft.world.entity.boss.wither with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionboolean
WitherBoss.addEffect
(MobEffectInstance p_182397_, Entity p_182398_) boolean
WitherBoss.canBeAffected
(MobEffectInstance p_31495_) -
Uses of MobEffectInstance in net.minecraft.world.entity.monster
Methods in net.minecraft.world.entity.monster with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionboolean
Spider.canBeAffected
(MobEffectInstance p_33809_) boolean
WitherSkeleton.canBeAffected
(MobEffectInstance p_34192_) -
Uses of MobEffectInstance in net.minecraft.world.entity.projectile
Methods in net.minecraft.world.entity.projectile with parameters of type MobEffectInstance -
Uses of MobEffectInstance in net.minecraft.world.item.alchemy
Fields in net.minecraft.world.item.alchemy with type parameters of type MobEffectInstanceModifier and TypeFieldDescriptionprivate final List
<MobEffectInstance> PotionContents.customEffects
The field for thecustomEffects
record component.private final List
<MobEffectInstance> Potion.effects
Methods in net.minecraft.world.item.alchemy that return types with arguments of type MobEffectInstanceModifier and TypeMethodDescriptionPotionContents.customEffects()
Returns the value of thecustomEffects
record component.PotionContents.getAllEffects()
Potion.getEffects()
Methods in net.minecraft.world.item.alchemy with parameters of type MobEffectInstanceMethod parameters in net.minecraft.world.item.alchemy with type arguments of type MobEffectInstanceModifier and TypeMethodDescriptionstatic void
PotionContents.addPotionTooltip
(Iterable<MobEffectInstance> p_331825_, Consumer<Component> p_331296_, float p_332038_, float p_332014_) void
PotionContents.forEachEffect
(Consumer<MobEffectInstance> p_331190_, float p_394070_) static OptionalInt
PotionContents.getColorOptional
(Iterable<MobEffectInstance> p_332699_) Constructors in net.minecraft.world.item.alchemy with parameters of type MobEffectInstanceConstructor parameters in net.minecraft.world.item.alchemy with type arguments of type MobEffectInstanceModifierConstructorDescriptionPotionContents
(Optional<Holder<Potion>> potion, Optional<Integer> customColor, List<MobEffectInstance> customEffects, Optional<String> customName) Creates an instance of aPotionContents
record class. -
Uses of MobEffectInstance in net.minecraft.world.item.component
Methods in net.minecraft.world.item.component that return MobEffectInstance -
Uses of MobEffectInstance in net.minecraft.world.item.consume_effects
Fields in net.minecraft.world.item.consume_effects with type parameters of type MobEffectInstanceModifier and TypeFieldDescriptionprivate final List
<MobEffectInstance> ApplyStatusEffectsConsumeEffect.effects
The field for theeffects
record component.Methods in net.minecraft.world.item.consume_effects that return types with arguments of type MobEffectInstanceModifier and TypeMethodDescriptionApplyStatusEffectsConsumeEffect.effects()
Returns the value of theeffects
record component.Constructors in net.minecraft.world.item.consume_effects with parameters of type MobEffectInstanceModifierConstructorDescriptionApplyStatusEffectsConsumeEffect
(MobEffectInstance p_366678_) ApplyStatusEffectsConsumeEffect
(MobEffectInstance p_366514_, float p_366567_) Constructor parameters in net.minecraft.world.item.consume_effects with type arguments of type MobEffectInstanceModifierConstructorDescriptionApplyStatusEffectsConsumeEffect
(List<MobEffectInstance> p_366447_) ApplyStatusEffectsConsumeEffect
(List<MobEffectInstance> effects, float probability) Creates an instance of aApplyStatusEffectsConsumeEffect
record class. -
Uses of MobEffectInstance in net.minecraft.world.level.block
Methods in net.minecraft.world.level.block that return MobEffectInstanceModifier and TypeMethodDescriptionEyeblossomBlock.getBeeInteractionEffect()
FlowerBlock.getBeeInteractionEffect()
WitherRoseBlock.getBeeInteractionEffect()
-
Uses of MobEffectInstance in net.neoforged.neoforge.client
Methods in net.neoforged.neoforge.client with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionClientHooks.getEffectTooltip
(AbstractContainerScreen<?> screen, MobEffectInstance effectInst, List<Component> tooltip) Fires theGatherEffectScreenTooltipsEvent
and returns the resulting tooltip lines.static boolean
ClientHooks.shouldRenderEffect
(MobEffectInstance effectInstance) -
Uses of MobEffectInstance in net.neoforged.neoforge.client.event
Fields in net.neoforged.neoforge.client.event declared as MobEffectInstanceModifier and TypeFieldDescriptionprotected final MobEffectInstance
GatherEffectScreenTooltipsEvent.effectInst
Methods in net.neoforged.neoforge.client.event that return MobEffectInstanceConstructors in net.neoforged.neoforge.client.event with parameters of type MobEffectInstanceModifierConstructorDescriptionGatherEffectScreenTooltipsEvent
(AbstractContainerScreen<?> screen, MobEffectInstance effectInst, List<Component> tooltip) -
Uses of MobEffectInstance in net.neoforged.neoforge.client.extensions.common
Methods in net.neoforged.neoforge.client.extensions.common with parameters of type MobEffectInstanceModifier and TypeMethodDescriptiondefault boolean
IClientMobEffectExtensions.isVisibleInGui
(MobEffectInstance instance) Queries whether the given effect should be shown in the HUD.default boolean
IClientMobEffectExtensions.isVisibleInInventory
(MobEffectInstance instance) Queries whether the given effect should be shown in the player's inventory.static IClientMobEffectExtensions
IClientMobEffectExtensions.of
(MobEffectInstance instance) default boolean
IClientMobEffectExtensions.renderGuiIcon
(MobEffectInstance instance, Gui gui, GuiGraphics guiGraphics, int x, int y, float z, float alpha) Renders the icon of the specified effect on the player's HUD.default boolean
IClientMobEffectExtensions.renderInventoryIcon
(MobEffectInstance instance, AbstractContainerScreen<?> screen, GuiGraphics guiGraphics, int x, int y, int blitOffset) Renders the icon of the specified effect in the player's inventory.default boolean
IClientMobEffectExtensions.renderInventoryText
(MobEffectInstance instance, AbstractContainerScreen<?> screen, GuiGraphics guiGraphics, int x, int y, int blitOffset) Renders the text of the specified effect in the player's inventory. -
Uses of MobEffectInstance in net.neoforged.neoforge.common
Methods in net.neoforged.neoforge.common with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionstatic boolean
CommonHooks.canMobEffectBeApplied
(LivingEntity entity, MobEffectInstance effect, @Nullable Entity source) Checks if a mob effect can be applied to an entity by firingMobEffectEvent.Applicable
. -
Uses of MobEffectInstance in net.neoforged.neoforge.common.extensions
Methods in net.neoforged.neoforge.common.extensions with parameters of type MobEffectInstanceModifier and TypeMethodDescriptiondefault int
IMobEffectExtension.getSortOrder
(MobEffectInstance effectInstance) Used for determiningMobEffect
sort order in GUIs. -
Uses of MobEffectInstance in net.neoforged.neoforge.event
Methods in net.neoforged.neoforge.event with parameters of type MobEffectInstanceModifier and TypeMethodDescriptionstatic boolean
EventHooks.onEffectRemoved
(LivingEntity entity, MobEffectInstance effectInstance) -
Uses of MobEffectInstance in net.neoforged.neoforge.event.entity.living
Fields in net.neoforged.neoforge.event.entity.living declared as MobEffectInstanceModifier and TypeFieldDescriptionprivate final MobEffectInstance
EffectParticleModificationEvent.effect
protected final @Nullable MobEffectInstance
MobEffectEvent.effectInstance
private final MobEffectInstance
MobEffectEvent.Added.oldEffectInstance
Methods in net.neoforged.neoforge.event.entity.living that return MobEffectInstanceModifier and TypeMethodDescriptionEffectParticleModificationEvent.getEffect()
MobEffectEvent.Added.getEffectInstance()
MobEffectEvent.Applicable.getEffectInstance()
@Nullable MobEffectInstance
MobEffectEvent.getEffectInstance()
@Nullable MobEffectInstance
MobEffectEvent.Remove.getEffectInstance()
@Nullable MobEffectInstance
MobEffectEvent.Added.getOldEffectInstance()
Constructors in net.neoforged.neoforge.event.entity.living with parameters of type MobEffectInstanceModifierConstructorDescriptionAdded
(LivingEntity living, MobEffectInstance oldEffectInstance, MobEffectInstance newEffectInstance, Entity source) Applicable
(LivingEntity living, MobEffectInstance effectInstance, @Nullable Entity source) EffectParticleModificationEvent
(LivingEntity entity, MobEffectInstance effect) Expired
(LivingEntity living, MobEffectInstance effectInstance) protected
MobEffectEvent
(LivingEntity living, MobEffectInstance effectInstance) Remove
(LivingEntity living, MobEffectInstance effectInstance)