From 54f230de84387df8c38eff381c18c752f1f325a0 Mon Sep 17 00:00:00 2001 From: CraftBukkit/Spigot Date: Fri, 10 May 2024 19:09:20 +1000 Subject: [PATCH] SPIGOT-7665: Fix ThrownPotion#getEffects() implementation only bringing custom effects By: Doc --- .../java/org/bukkit/craftbukkit/entity/CraftThrownPotion.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/paper-server/src/main/java/org/bukkit/craftbukkit/entity/CraftThrownPotion.java b/paper-server/src/main/java/org/bukkit/craftbukkit/entity/CraftThrownPotion.java index cb0fd8239e..868b3de947 100644 --- a/paper-server/src/main/java/org/bukkit/craftbukkit/entity/CraftThrownPotion.java +++ b/paper-server/src/main/java/org/bukkit/craftbukkit/entity/CraftThrownPotion.java @@ -23,7 +23,7 @@ public class CraftThrownPotion extends CraftThrowableProjectile implements Throw @Override public Collection getEffects() { ImmutableList.Builder builder = ImmutableList.builder(); - for (MobEffect effect : getHandle().getItem().getOrDefault(DataComponents.POTION_CONTENTS, PotionContents.EMPTY).customEffects()) { + for (MobEffect effect : getHandle().getItem().getOrDefault(DataComponents.POTION_CONTENTS, PotionContents.EMPTY).getAllEffects()) { builder.add(CraftPotionUtil.toBukkit(effect)); } return builder.build();