summaryrefslogtreecommitdiffstats
path: root/src/main/java/org/bukkit/entity/LivingEntity.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/org/bukkit/entity/LivingEntity.java')
-rw-r--r--src/main/java/org/bukkit/entity/LivingEntity.java15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/main/java/org/bukkit/entity/LivingEntity.java b/src/main/java/org/bukkit/entity/LivingEntity.java
index a6b4e9b2..3c0f4cae 100644
--- a/src/main/java/org/bukkit/entity/LivingEntity.java
+++ b/src/main/java/org/bukkit/entity/LivingEntity.java
@@ -90,25 +90,40 @@ public interface LivingEntity extends Entity {
/**
* Throws an egg from the entity.
*
+ * @deprecated Use launchProjectile(Egg.class) instead
* @return The egg thrown.
*/
+ @Deprecated
public Egg throwEgg();
/**
* Throws a snowball from the entity.
*
+ * @deprecated Use launchProjectile(Snowball.class) instead
* @return The snowball thrown.
*/
+ @Deprecated
public Snowball throwSnowball();
/**
* Shoots an arrow from the entity.
*
+ * @deprecated Use launchProjectile(Arrow.class) instead
* @return The arrow shot.
*/
+ @Deprecated
public Arrow shootArrow();
/**
+ * Launches a {@link Projectile} from the entity.
+ *
+ * @param projectile Class of the projectile to launch
+ *
+ * @return The launched projectile.
+ */
+ public <T extends Projectile> T launchProjectile(Class<? extends T> projectile);
+
+ /**
* Returns whether this entity is inside a vehicle.
*
* @return True if the entity is in a vehicle.