mirror of
https://github.com/PaperMC/Paper.git
synced 2025-07-31 20:22:05 -07:00
Fix potion effect type removal (#11778)
An incorrectly updated hunk attempted to remove the MobEffectInstance from the active effect map instead of the Holder<MobEffect> as the parameter name was changed from holder to effect during hardfork.
This commit is contained in:
@@ -388,7 +388,6 @@
|
|||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
public MobEffectInstance removeEffectNoUpdate(Holder<MobEffect> effect) {
|
public MobEffectInstance removeEffectNoUpdate(Holder<MobEffect> effect) {
|
||||||
- return this.activeEffects.remove(effect);
|
|
||||||
+ // CraftBukkit start
|
+ // CraftBukkit start
|
||||||
+ return this.removeEffectNoUpdate(effect, org.bukkit.event.entity.EntityPotionEffectEvent.Cause.UNKNOWN);
|
+ return this.removeEffectNoUpdate(effect, org.bukkit.event.entity.EntityPotionEffectEvent.Cause.UNKNOWN);
|
||||||
+ }
|
+ }
|
||||||
@@ -410,7 +409,7 @@
|
|||||||
+ return null;
|
+ return null;
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
+ return this.activeEffects.remove(effectInstance);
|
return this.activeEffects.remove(effect);
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean removeEffect(Holder<MobEffect> effect) {
|
public boolean removeEffect(Holder<MobEffect> effect) {
|
||||||
|
Reference in New Issue
Block a user