SPIGOT-840, SPIGOT-2522: [Draft] Add EntityPotionEffectChangeEvent
Discussion ongoing in PR #449 By: kaenganxt <kaenganxt@mc-anura.de>
This commit is contained in:
17
paper-server/nms-patches/ItemFish.patch
Normal file
17
paper-server/nms-patches/ItemFish.patch
Normal file
@@ -0,0 +1,17 @@
|
||||
--- a/net/minecraft/server/ItemFish.java
|
||||
+++ b/net/minecraft/server/ItemFish.java
|
||||
@@ -25,9 +25,11 @@
|
||||
ItemFish.EnumFish itemfish_enumfish = ItemFish.EnumFish.a(itemstack);
|
||||
|
||||
if (itemfish_enumfish == ItemFish.EnumFish.PUFFERFISH) {
|
||||
- entityhuman.addEffect(new MobEffect(MobEffects.POISON, 1200, 3));
|
||||
- entityhuman.addEffect(new MobEffect(MobEffects.HUNGER, 300, 2));
|
||||
- entityhuman.addEffect(new MobEffect(MobEffects.CONFUSION, 300, 1));
|
||||
+ // CraftBukkit start
|
||||
+ entityhuman.addEffect(new MobEffect(MobEffects.POISON, 1200, 3), org.bukkit.event.entity.EntityPotionEffectEvent.Cause.FOOD);
|
||||
+ entityhuman.addEffect(new MobEffect(MobEffects.HUNGER, 300, 2), org.bukkit.event.entity.EntityPotionEffectEvent.Cause.FOOD);
|
||||
+ entityhuman.addEffect(new MobEffect(MobEffects.CONFUSION, 300, 1), org.bukkit.event.entity.EntityPotionEffectEvent.Cause.FOOD);
|
||||
+ // CraftBukkit end
|
||||
}
|
||||
|
||||
super.a(itemstack, world, entityhuman);
|
||||
Reference in New Issue
Block a user