diff options
author | kaenganxt <kaenganxt@mc-anura.de> | 2018-07-20 16:04:37 +1000 |
---|---|---|
committer | md_5 <git@md-5.net> | 2018-07-20 16:06:34 +1000 |
commit | 814c742554e40554a30cee1915b42457081000c6 (patch) | |
tree | ab1cc74348447c556db92576fd282ab465c70f3d /nms-patches/EntityTippedArrow.patch | |
parent | fa6e97a8f8c57e0a5bbd046fe9af3d795a2c11b5 (diff) | |
download | craftbukkit-814c742554e40554a30cee1915b42457081000c6.tar craftbukkit-814c742554e40554a30cee1915b42457081000c6.tar.gz craftbukkit-814c742554e40554a30cee1915b42457081000c6.tar.lz craftbukkit-814c742554e40554a30cee1915b42457081000c6.tar.xz craftbukkit-814c742554e40554a30cee1915b42457081000c6.zip |
SPIGOT-840, SPIGOT-2522: [Draft] Add EntityPotionEffectChangeEvent
Discussion ongoing in PR #449
Diffstat (limited to 'nms-patches/EntityTippedArrow.patch')
-rw-r--r-- | nms-patches/EntityTippedArrow.patch | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/nms-patches/EntityTippedArrow.patch b/nms-patches/EntityTippedArrow.patch index 12e28241..b3e1578b 100644 --- a/nms-patches/EntityTippedArrow.patch +++ b/nms-patches/EntityTippedArrow.patch @@ -26,3 +26,21 @@ public int getColor() { return ((Integer) this.datawatcher.get(EntityTippedArrow.f)).intValue(); } +@@ -180,7 +199,7 @@ + + while (iterator.hasNext()) { + mobeffect = (MobEffect) iterator.next(); +- entityliving.addEffect(new MobEffect(mobeffect.getMobEffect(), Math.max(mobeffect.getDuration() / 8, 1), mobeffect.getAmplifier(), mobeffect.isAmbient(), mobeffect.isShowParticles())); ++ entityliving.addEffect(new MobEffect(mobeffect.getMobEffect(), Math.max(mobeffect.getDuration() / 8, 1), mobeffect.getAmplifier(), mobeffect.isAmbient(), mobeffect.isShowParticles()), org.bukkit.event.entity.EntityPotionEffectEvent.Cause.ARROW); // CraftBukkit + } + + if (!this.effects.isEmpty()) { +@@ -188,7 +207,7 @@ + + while (iterator.hasNext()) { + mobeffect = (MobEffect) iterator.next(); +- entityliving.addEffect(mobeffect); ++ entityliving.addEffect(mobeffect, org.bukkit.event.entity.EntityPotionEffectEvent.Cause.ARROW); // CraftBukkit + } + } + |