PaperMC/paper-server/nms-patches/net/minecraft/world/entity/projectile/EntityTippedArrow.patch
CraftBukkit/Spigot eed041d629 Update to Minecraft 1.21
By: md_5 <git@md-5.net>
2024-06-14 01:05:00 +10:00

20 lines
1,004 B
Diff

--- a/net/minecraft/world/entity/projectile/EntityTippedArrow.java
+++ b/net/minecraft/world/entity/projectile/EntityTippedArrow.java
@@ -119,7 +119,7 @@
mobeffect = (MobEffect) iterator.next();
entityliving.addEffect(new MobEffect(mobeffect.getEffect(), Math.max(mobeffect.mapDuration((i) -> {
return i / 8;
- }), 1), mobeffect.getAmplifier(), mobeffect.isAmbient(), mobeffect.isVisible()), entity);
+ }), 1), mobeffect.getAmplifier(), mobeffect.isAmbient(), mobeffect.isVisible()), entity, org.bukkit.event.entity.EntityPotionEffectEvent.Cause.ARROW); // CraftBukkit
}
}
@@ -127,7 +127,7 @@
while (iterator.hasNext()) {
mobeffect = (MobEffect) iterator.next();
- entityliving.addEffect(mobeffect, entity);
+ entityliving.addEffect(mobeffect, entity, org.bukkit.event.entity.EntityPotionEffectEvent.Cause.ARROW); // CraftBukkit
}
}