Bukkit-API  1.7.9-R0.2
The inofficial Bukkit-API
org.bukkit.entity.EntityType Enum Reference

Public Member Functions

String getName ()
Class<?extends EntitygetEntityClass ()
short getTypeId ()
boolean isSpawnable ()
boolean isAlive ()

Static Public Member Functions

 [static initializer]
static EntityType fromName (String name)
static EntityType fromId (int id)

Public Attributes

 DROPPED_ITEM =("Item", Item.class, 1, false)
 EXPERIENCE_ORB =("XPOrb", ExperienceOrb.class, 2)
 LEASH_HITCH =("LeashKnot", LeashHitch.class, 8)
 PAINTING =("Painting", Painting.class, 9)
 ARROW =("Arrow", Arrow.class, 10)
 SNOWBALL =("Snowball", Snowball.class, 11)
 FIREBALL =("Fireball", LargeFireball.class, 12)
 SMALL_FIREBALL =("SmallFireball", SmallFireball.class, 13)
 ENDER_PEARL =("ThrownEnderpearl", EnderPearl.class, 14)
 ENDER_SIGNAL =("EyeOfEnderSignal", EnderSignal.class, 15)
 THROWN_EXP_BOTTLE =("ThrownExpBottle", ThrownExpBottle.class, 17)
 ITEM_FRAME =("ItemFrame", ItemFrame.class, 18)
 WITHER_SKULL =("WitherSkull", WitherSkull.class, 19)
 PRIMED_TNT =("PrimedTnt", TNTPrimed.class, 20)
 FALLING_BLOCK =("FallingSand", FallingBlock.class, 21, false)
 FIREWORK =("FireworksRocketEntity", Firework.class, 22, false)
 MINECART_COMMAND =("MinecartCommandBlock", CommandMinecart.class, 40)
 BOAT =("Boat", Boat.class, 41)
 MINECART =("MinecartRideable", RideableMinecart.class, 42)
 MINECART_CHEST =("MinecartChest", StorageMinecart.class, 43)
 MINECART_FURNACE =("MinecartFurnace", PoweredMinecart.class, 44)
 MINECART_TNT =("MinecartTNT", ExplosiveMinecart.class, 45)
 MINECART_HOPPER =("MinecartHopper", HopperMinecart.class, 46)
 MINECART_MOB_SPAWNER =("MinecartMobSpawner", SpawnerMinecart.class, 47)
 CREEPER =("Creeper", Creeper.class, 50)
 SKELETON =("Skeleton", Skeleton.class, 51)
 SPIDER =("Spider", Spider.class, 52)
 GIANT =("Giant", Giant.class, 53)
 ZOMBIE =("Zombie", Zombie.class, 54)
 SLIME =("Slime", Slime.class, 55)
 GHAST =("Ghast", Ghast.class, 56)
 PIG_ZOMBIE =("PigZombie", PigZombie.class, 57)
 ENDERMAN =("Enderman", Enderman.class, 58)
 CAVE_SPIDER =("CaveSpider", CaveSpider.class, 59)
 SILVERFISH =("Silverfish", Silverfish.class, 60)
 BLAZE =("Blaze", Blaze.class, 61)
 MAGMA_CUBE =("LavaSlime", MagmaCube.class, 62)
 ENDER_DRAGON =("EnderDragon", EnderDragon.class, 63)
 WITHER =("WitherBoss", Wither.class, 64)
 BAT =("Bat", Bat.class, 65)
 WITCH =("Witch", Witch.class, 66)
 PIG =("Pig", Pig.class, 90)
 SHEEP =("Sheep", Sheep.class, 91)
 COW =("Cow", Cow.class, 92)
 CHICKEN =("Chicken", Chicken.class, 93)
 SQUID =("Squid", Squid.class, 94)
 WOLF =("Wolf", Wolf.class, 95)
 MUSHROOM_COW =("MushroomCow", MushroomCow.class, 96)
 SNOWMAN =("SnowMan", Snowman.class, 97)
 OCELOT =("Ozelot", Ocelot.class, 98)
 IRON_GOLEM =("VillagerGolem", IronGolem.class, 99)
 HORSE =("EntityHorse", Horse.class, 100)
 VILLAGER =("Villager", Villager.class, 120)
 ENDER_CRYSTAL =("EnderCrystal", EnderCrystal.class, 200)
 SPLASH_POTION =(null, ThrownPotion.class, -1, false)
 EGG =(null, Egg.class, -1, false)
 FISHING_HOOK =(null, Fish.class, -1, false)
 LIGHTNING =(null, LightningStrike.class, -1, false)
 WEATHER =(null, Weather.class, -1, false)
 PLAYER =(null, Player.class, -1, false)
 COMPLEX_PART =(null, ComplexEntityPart.class, -1, false)
 UNKNOWN =(null, null, -1, false)
boolean living

Detailed Description

Definition at line 17 of file EntityType.java.

Member Function Documentation

static EntityType org.bukkit.entity.EntityType.fromId ( int  id)
Magic value

Definition at line 245 of file EntityType.java.

Referenced by org.bukkit.material.SpawnEgg.getSpawnedType().

245  {
246  if (id > Short.MAX_VALUE) {
247  return null;
248  }
249  return ID_MAP.get((short) id);
250  }
static EntityType org.bukkit.entity.EntityType.fromName ( String  name)
Magic value

Definition at line 233 of file EntityType.java.

233  {
234  if (name == null) {
235  return null;
236  }
237  return NAME_MAP.get(name.toLowerCase());
238  }
String org.bukkit.entity.EntityType.getName ( )
Magic value

Definition at line 211 of file EntityType.java.

211  {
212  return name;
213  }
short org.bukkit.entity.EntityType.getTypeId ( )
Magic value

Definition at line 224 of file EntityType.java.

Referenced by org.bukkit.material.SpawnEgg.setSpawnedType().

224  {
225  return typeId;
226  }
boolean org.bukkit.entity.EntityType.isSpawnable ( )

Some entities cannot be spawned using World#spawnEntity(Location, EntityType) or World#spawn(Location, Class), usually because they require additional information in order to spawn.

False if the entity type cannot be spawned

Definition at line 260 of file EntityType.java.

Referenced by org.bukkit.event.player.PlayerEggThrowEvent.setHatchingType().

260  {
261  return independent;
262  }

Member Data Documentation

org.bukkit.entity.EntityType.ARROW =("Arrow", Arrow.class, 10)

An arrow projectile; may get stuck in the ground.

Definition at line 42 of file EntityType.java.

org.bukkit.entity.EntityType.BOAT =("Boat", Boat.class, 41)

A placed boat.

Definition at line 91 of file EntityType.java.

org.bukkit.entity.EntityType.DROPPED_ITEM =("Item", Item.class, 1, false)

An item resting on the ground.

Spawn with World#dropItem(Location, ItemStack) or World#dropItemNaturally(Location, ItemStack)

Definition at line 26 of file EntityType.java.

org.bukkit.entity.EntityType.EGG =(null, Egg.class, -1, false)

A flying chicken egg.

Definition at line 154 of file EntityType.java.

org.bukkit.entity.EntityType.ENDER_PEARL =("ThrownEnderpearl", EnderPearl.class, 14)

A flying ender pearl.

Definition at line 58 of file EntityType.java.

org.bukkit.entity.EntityType.ENDER_SIGNAL =("EyeOfEnderSignal", EnderSignal.class, 15)

An ender eye signal.

Definition at line 62 of file EntityType.java.

org.bukkit.entity.EntityType.EXPERIENCE_ORB =("XPOrb", ExperienceOrb.class, 2)

An experience orb.

Definition at line 30 of file EntityType.java.

org.bukkit.entity.EntityType.FALLING_BLOCK =("FallingSand", FallingBlock.class, 21, false)

A block that is going to or is about to fall.

Definition at line 82 of file EntityType.java.

org.bukkit.entity.EntityType.FIREBALL =("Fireball", LargeFireball.class, 12)

A flying large fireball, as thrown by a Ghast for example.

Definition at line 50 of file EntityType.java.

org.bukkit.entity.EntityType.FISHING_HOOK =(null, Fish.class, -1, false)

A fishing line and bobber.

Definition at line 158 of file EntityType.java.

org.bukkit.entity.EntityType.ITEM_FRAME =("ItemFrame", ItemFrame.class, 18)

An item frame on a wall.

Definition at line 70 of file EntityType.java.

org.bukkit.entity.EntityType.LEASH_HITCH =("LeashKnot", LeashHitch.class, 8)

A leash attached to a fencepost.

Definition at line 34 of file EntityType.java.

org.bukkit.entity.EntityType.LIGHTNING =(null, LightningStrike.class, -1, false)

A bolt of lightning.

Spawn with World#strikeLightning(Location).

Definition at line 164 of file EntityType.java.

org.bukkit.entity.EntityType.MINECART =("MinecartRideable", RideableMinecart.class, 42)
See also

Definition at line 95 of file EntityType.java.

org.bukkit.entity.EntityType.MINECART_CHEST =("MinecartChest", StorageMinecart.class, 43)
See also

Definition at line 99 of file EntityType.java.

org.bukkit.entity.EntityType.MINECART_COMMAND =("MinecartCommandBlock", CommandMinecart.class, 40)
See also

Definition at line 87 of file EntityType.java.

org.bukkit.entity.EntityType.MINECART_FURNACE =("MinecartFurnace", PoweredMinecart.class, 44)
See also

Definition at line 103 of file EntityType.java.

org.bukkit.entity.EntityType.MINECART_HOPPER =("MinecartHopper", HopperMinecart.class, 46)
See also

Definition at line 111 of file EntityType.java.

org.bukkit.entity.EntityType.MINECART_MOB_SPAWNER =("MinecartMobSpawner", SpawnerMinecart.class, 47)
See also

Definition at line 115 of file EntityType.java.

org.bukkit.entity.EntityType.MINECART_TNT =("MinecartTNT", ExplosiveMinecart.class, 45)
See also

Definition at line 107 of file EntityType.java.

org.bukkit.entity.EntityType.PAINTING =("Painting", Painting.class, 9)

A painting on a wall.

Definition at line 38 of file EntityType.java.

org.bukkit.entity.EntityType.PRIMED_TNT =("PrimedTnt", TNTPrimed.class, 20)

Primed TNT that is about to explode.

Definition at line 78 of file EntityType.java.

org.bukkit.entity.EntityType.SMALL_FIREBALL =("SmallFireball", SmallFireball.class, 13)

A flying small fireball, such as thrown by a Blaze or player.

Definition at line 54 of file EntityType.java.

org.bukkit.entity.EntityType.SNOWBALL =("Snowball", Snowball.class, 11)

A flying snowball.

Definition at line 46 of file EntityType.java.

org.bukkit.entity.EntityType.SPLASH_POTION =(null, ThrownPotion.class, -1, false)

A flying splash potion.

Definition at line 150 of file EntityType.java.

org.bukkit.entity.EntityType.THROWN_EXP_BOTTLE =("ThrownExpBottle", ThrownExpBottle.class, 17)

A flying experience bottle.

Definition at line 66 of file EntityType.java.

org.bukkit.entity.EntityType.UNKNOWN =(null, null, -1, false)

An unknown entity without an Entity Class

Definition at line 171 of file EntityType.java.

org.bukkit.entity.EntityType.WITHER_SKULL =("WitherSkull", WitherSkull.class, 19)

A flying wither skull projectile.

Definition at line 74 of file EntityType.java.

The documentation for this enum was generated from the following file: