PaperMC/paper-server/nms-patches/net/minecraft/world/item/ItemPotion.patch

12 lines
607 B
Diff
Raw Normal View History

2021-03-15 23:00:00 +01:00
--- a/net/minecraft/world/item/ItemPotion.java
+++ b/net/minecraft/world/item/ItemPotion.java
@@ -52,7 +52,7 @@
if (mobeffect.getMobEffect().isInstant()) {
mobeffect.getMobEffect().applyInstantEffect(entityhuman, entityhuman, entityliving, mobeffect.getAmplifier(), 1.0D);
} else {
- entityliving.addEffect(new MobEffect(mobeffect));
+ entityliving.addEffect(new MobEffect(mobeffect), org.bukkit.event.entity.EntityPotionEffectEvent.Cause.POTION_DRINK); // CraftBukkit
}
}
}