2025-03-26 03:05:00 +11:00

12 lines
807 B
Diff

--- a/net/minecraft/world/entity/monster/EntityWitch.java
+++ b/net/minecraft/world/entity/monster/EntityWitch.java
@@ -126,7 +126,7 @@
PotionContents potioncontents = (PotionContents) itemstack.get(DataComponents.POTION_CONTENTS);
if (itemstack.is(Items.POTION) && potioncontents != null) {
- potioncontents.forEachEffect(this::addEffect, (Float) itemstack.getOrDefault(DataComponents.POTION_DURATION_SCALE, 1.0F));
+ potioncontents.forEachEffect((effect) -> this.addEffect(effect, org.bukkit.event.entity.EntityPotionEffectEvent.Cause.ATTACK), (Float) itemstack.getOrDefault(DataComponents.POTION_DURATION_SCALE, 1.0F)); // CraftBukkit
}
this.gameEvent(GameEvent.DRINK);