blob: 81dcecb8d73ae0bf9ab69b38603f0b807b37030e (
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
33
34
35
36
37
38
39
40
41
|
package org.bukkit.entity;
import java.util.Collection;
import org.bukkit.inventory.ItemStack;
import org.bukkit.potion.PotionEffect;
/**
* Represents a thrown potion bottle
*/
public interface ThrownPotion extends Projectile {
/**
* Returns the effects that are applied by this potion.
*
* @return The potion effects
*/
public Collection<PotionEffect> getEffects();
/**
* Returns a copy of the ItemStack for this thrown potion.
* <p>
* Altering this copy will not alter the thrown potion directly. If you want
* to alter the thrown potion, you must use the {@link
* #setItem(ItemStack) setItemStack} method.
*
* @return A copy of the ItemStack for this thrown potion.
*/
public ItemStack getItem();
/**
* Set the ItemStack for this thrown potion.
* <p>
* The ItemStack must be of type {@link org.bukkit.Material#SPLASH_POTION}
* or {@link org.bukkit.Material#LINGERING_POTION}, otherwise an exception
* is thrown.
*
* @param item New ItemStack
*/
public void setItem(ItemStack item);
}
|