aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/server/0725-Missing-effect-cause.patch
blob: 85e40f7bb17e613ab4f206d66e5205119430a08b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Lulu13022002 <41980282+Lulu13022002@users.noreply.github.com>
Date: Tue, 16 Aug 2022 19:44:55 +0200
Subject: [PATCH] Missing effect cause


diff --git a/src/main/java/net/minecraft/world/entity/animal/Bee.java b/src/main/java/net/minecraft/world/entity/animal/Bee.java
index ca706f1ac5f4248164daa613eef81e46b3e5a210..0bafe14342c1acce131ad34717c18aed3718deed 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Bee.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Bee.java
@@ -636,7 +636,7 @@ public class Bee extends Animal implements NeutralMob, FlyingAnimal {
                     if (mobeffect != null) {
                         this.usePlayerItem(player, hand, itemstack);
                         if (!this.level().isClientSide) {
-                            this.addEffect(mobeffect);
+                            this.addEffect(mobeffect, org.bukkit.event.entity.EntityPotionEffectEvent.Cause.FOOD); // Paper - Add missing effect cause
                         }
 
                         return InteractionResult.SUCCESS;
diff --git a/src/main/java/net/minecraft/world/entity/animal/axolotl/Axolotl.java b/src/main/java/net/minecraft/world/entity/animal/axolotl/Axolotl.java
index 068d96cd0bceec79f14fbf3289eeb81533d1ba22..31b10cd404b672d7ce21c2107d8f83e32de26ef4 100644
--- a/src/main/java/net/minecraft/world/entity/animal/axolotl/Axolotl.java
+++ b/src/main/java/net/minecraft/world/entity/animal/axolotl/Axolotl.java
@@ -424,7 +424,7 @@ public class Axolotl extends Animal implements VariantHolder<Axolotl.Variant>, B
             player.addEffect(new MobEffectInstance(MobEffects.REGENERATION, j, 0), this, org.bukkit.event.entity.EntityPotionEffectEvent.Cause.AXOLOTL); // CraftBukkit
         }
 
-        player.removeEffect(MobEffects.DIG_SLOWDOWN);
+        player.removeEffect(MobEffects.DIG_SLOWDOWN, org.bukkit.event.entity.EntityPotionEffectEvent.Cause.AXOLOTL); // Paper - Add missing effect cause
     }
 
     @Override