Package org.bukkit.material
Class SpawnEgg
java.lang.Object
org.bukkit.material.MaterialData
org.bukkit.material.SpawnEgg
- All Implemented Interfaces:
java.lang.Cloneable
public class SpawnEgg extends MaterialData
Represents a spawn egg that can be used to spawn mobs
-
Constructor Summary
Constructors Constructor Description SpawnEgg()SpawnEgg(byte data)Deprecated.Magic valueSpawnEgg(int type, byte data)Deprecated.Magic valueSpawnEgg(EntityType type) -
Method Summary
Modifier and Type Method Description SpawnEggclone()EntityTypegetSpawnedType()Get the type of entity this egg will spawn.voidsetSpawnedType(EntityType type)Set the type of entity this egg will spawn.java.lang.StringtoString()Methods inherited from class org.bukkit.material.MaterialData
equals, getData, getItemType, getItemTypeId, hashCode, setData, toItemStack, toItemStack
-
Constructor Details
-
Method Details
-
getSpawnedType
Get the type of entity this egg will spawn.- Returns:
- The entity type.
-
setSpawnedType
Set the type of entity this egg will spawn.- Parameters:
type- The entity type.
-
toString
public java.lang.String toString()- Overrides:
toStringin classMaterialData
-
clone
- Overrides:
clonein classMaterialData
-