PaperMC/nms-patches/ItemPotion.patch

12 lines
599 B
Diff
Raw Normal View History

--- a/net/minecraft/server/ItemPotion.java
+++ b/net/minecraft/server/ItemPotion.java
2020-06-25 02:00:00 +02:00
@@ -32,7 +32,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
}
}
}