-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Minor
-
None
-
Affects Version/s: None
-
None
-
4156-Spigot-e2c1eee-428aefe (MC: 1.20.6) (Implementing API version 1.20.6-R0.1-SNAPSHOT)
-
Yes
should be
for (MobEffectInstance effect : this.getHandle().getItem().getOrDefault(DataComponents.POTION_CONTENTS, PotionContents.EMPTY).getAllEffects()) {
@EventHandler public void onPotionSplash(PotionSplashEvent event) { ThrownPotion potion = event.getPotion(); Collection<PotionEffect> effects = event.getPotion().getEffects(); Bukkit.broadcastMessage("Potion effects: " + effects.size()); }
Example code prints 0 when throwing a strength potion on the ground