Interface FabricMobEffect
public interface FabricMobEffect
An extension for
MobEffect subclasses adding basic events.-
Method Summary
Modifier and TypeMethodDescriptiondefault voidonEffectAdded(net.minecraft.world.effect.MobEffectInstance effectInstance, net.minecraft.world.entity.LivingEntity entity) Called before an instance of this effect has been added to a living entity.default voidonEffectRemoved(net.minecraft.world.effect.MobEffectInstance effectInstance, net.minecraft.world.entity.LivingEntity entity) Called before an instance of this effect has been removed from a living entity.default voidonEffectStarted(net.minecraft.world.effect.MobEffectInstance effectInstance, net.minecraft.world.entity.LivingEntity entity) Called after an instance of this effect has been added to a living entity.
-
Method Details
-
onEffectAdded
default void onEffectAdded(net.minecraft.world.effect.MobEffectInstance effectInstance, net.minecraft.world.entity.LivingEntity entity) Called before an instance of this effect has been added to a living entity.- Parameters:
effectInstance- an instance of this effectentity- the entity the effect instance is being applied to
-
onEffectStarted
default void onEffectStarted(net.minecraft.world.effect.MobEffectInstance effectInstance, net.minecraft.world.entity.LivingEntity entity) Called after an instance of this effect has been added to a living entity.- Parameters:
effectInstance- an instance of this effectentity- the entity the effect instance has been applied to
-
onEffectRemoved
default void onEffectRemoved(net.minecraft.world.effect.MobEffectInstance effectInstance, net.minecraft.world.entity.LivingEntity entity) Called before an instance of this effect has been removed from a living entity.- Parameters:
effectInstance- an instance of this effectentity- the entity the effect instance is being removed from
-