public final class Entities extends Object
| Modifier and Type | Method and Description |
|---|---|
static org.bukkit.entity.Entity |
getShooter(org.bukkit.entity.Entity entity)
Get the underlying shooter of a projectile if one exists.
|
static boolean |
isAmbient(org.bukkit.entity.Entity entity)
Test whether an entity is ambient.
|
static boolean |
isConsideredBuildingIfUsed(org.bukkit.entity.Entity entity)
Test whether using the given entity should be considered "building"
rather than merely using an entity.
|
static boolean |
isFireball(org.bukkit.entity.EntityType type)
Return if the given entity type is a fireball
(not including wither skulls).
|
static boolean |
isHostile(org.bukkit.entity.Entity entity)
Test whether an entity is hostile.
|
static boolean |
isMinecart(org.bukkit.entity.EntityType type)
Test whether the given entity type is a Minecart type.
|
static boolean |
isNonHostile(org.bukkit.entity.Entity entity)
Test whether an entity is a non-hostile creature.
|
static boolean |
isNonPlayerCreature(org.bukkit.entity.Entity entity)
Test whether an entity is a creature (a living thing) that is
not a player.
|
static boolean |
isNPC(org.bukkit.entity.Entity entity)
Test whether an entity is an NPC.
|
static boolean |
isRiddenOnUse(org.bukkit.entity.Entity entity)
Test whether the given entity can be ridden if it is right clicked.
|
static boolean |
isTamed(org.bukkit.entity.Entity entity)
Test whether the given entity is tameable and tamed.
|
static boolean |
isTNTBased(org.bukkit.entity.Entity entity)
Return if the given entity type is TNT-based.
|
static boolean |
isVehicle(org.bukkit.entity.EntityType type)
Test whether the given entity type is a vehicle type.
|
public static boolean isTamed(@Nullable org.bukkit.entity.Entity entity)
entity - the entity, or nullpublic static boolean isTNTBased(org.bukkit.entity.Entity entity)
entity - the entitypublic static boolean isFireball(org.bukkit.entity.EntityType type)
type - the typepublic static boolean isRiddenOnUse(org.bukkit.entity.Entity entity)
entity - the entitypublic static boolean isVehicle(org.bukkit.entity.EntityType type)
type - the typepublic static boolean isMinecart(org.bukkit.entity.EntityType type)
type - the typepublic static org.bukkit.entity.Entity getShooter(org.bukkit.entity.Entity entity)
entity - the entitypublic static boolean isHostile(org.bukkit.entity.Entity entity)
entity - the entitypublic static boolean isNonHostile(org.bukkit.entity.Entity entity)
entity - public static boolean isAmbient(org.bukkit.entity.Entity entity)
entity - the entitypublic static boolean isNPC(org.bukkit.entity.Entity entity)
entity - the entitypublic static boolean isNonPlayerCreature(org.bukkit.entity.Entity entity)
entity - the entitypublic static boolean isConsideredBuildingIfUsed(org.bukkit.entity.Entity entity)
entity - the entityCopyright © 2015. All Rights Reserved.