Interface ArmorEquipable
-
- All Superinterfaces:
Equipable
- All Known Subinterfaces:
Aerial
,Ageable
,Agent
,Ambient
,Animal
,Aquatic
,ArmorStand
,Bat
,Bee
,Blaze
,Boss
,Cat
,CaveSpider
,Chicken
,ClientPlayer
,Cod
,Cow
,Creature
,Creeper
,Dolphin
,Donkey
,Drowned
,ElderGuardian
,EnderDragon
,Enderman
,Endermite
,Evoker
,Fish
,Fox
,Ghast
,Giant
,Golem
,Guardian
,Hoglin
,Horse
,HorseLike
,Hostile
,Human
,Humanoid
,Husk
,Illager
,Illusioner
,IronGolem
,Llama
,LlamaLike
,LocalPlayer
,MagmaCube
,Monster
,Mooshroom
,Mule
,Ocelot
,PackHorse
,Panda
,Parrot
,Patroller
,Phantom
,Pig
,Piglin
,PiglinBrute
,PiglinLike
,Pillager
,Player
,PolarBear
,Pufferfish
,Rabbit
,Raider
,Ranger
,Ravager
,RemotePlayer
,Salmon
,SchoolingFish
,ServerPlayer
,Sheep
,Shulker
,Silverfish
,Skeleton
,SkeletonHorse
,SkeletonLike
,Slime
,SnowGolem
,Spellcaster
,Spider
,Squid
,Stray
,Strider
,TameableAnimal
,TameableHorse
,Trader
,TraderLlama
,TropicalFish
,Turtle
,User
,Vex
,Villager
,Vindicator
,WanderingTrader
,Witch
,Wither
,WitherSkeleton
,Wolf
,Zoglin
,Zombie
,ZombieHorse
,ZombieLike
,ZombieVillager
,ZombifiedPiglin
public interface ArmorEquipable extends Equipable
Represents something that can be equipped with armor, main hand and off hand items. Each method here is a shorthand for the appropriate
Equipable.equipped(org.spongepowered.api.item.inventory.equipment.EquipmentType)
orEquipable.equip(org.spongepowered.api.item.inventory.equipment.EquipmentType, org.spongepowered.api.item.inventory.ItemStack)
method call.Classes implementing this interface should provide all of the supplied equipment slot types. Classes which do not support all slot types in this interface should instead implement
Equipable
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description ItemStack
chest()
Gets the chest.ItemStack
feet()
Gets the feet.ItemStack
head()
Gets the head.default ItemStack
itemInHand(java.util.function.Supplier<? extends HandType> handType)
Gets the equipped item in hand.ItemStack
itemInHand(HandType handType)
Gets the equipped item in hand.ItemStack
legs()
Gets the legs.void
setChest(ItemStack chest)
Sets the chest.void
setFeet(ItemStack feet)
Sets the feet.void
setHead(ItemStack head)
Sets the head.default void
setItemInHand(java.util.function.Supplier<? extends HandType> handType, ItemStack itemInHand)
Sets the equipped item in hand.void
setItemInHand(HandType handType, ItemStack itemInHand)
Sets the equipped item in hand.void
setLegs(ItemStack legs)
Sets the legs.
-
-
-
Method Detail
-
head
ItemStack head()
Gets the head.- Returns:
- The head, if available
-
setHead
void setHead(ItemStack head)
Sets the head.- Parameters:
head
- The head
-
chest
ItemStack chest()
Gets the chest.- Returns:
- The chest, if available
-
setChest
void setChest(ItemStack chest)
Sets the chest.- Parameters:
chest
- The chest
-
legs
ItemStack legs()
Gets the legs.- Returns:
- The legs, if available
-
setLegs
void setLegs(ItemStack legs)
Sets the legs.- Parameters:
legs
- The legs
-
feet
ItemStack feet()
Gets the feet.- Returns:
- The feet, if available
-
setFeet
void setFeet(ItemStack feet)
Sets the feet.- Parameters:
feet
- The feet
-
itemInHand
default ItemStack itemInHand(java.util.function.Supplier<? extends HandType> handType)
Gets the equipped item in hand.- Parameters:
handType
- The hand type to retrieve from- Returns:
- The item in hand, if available
-
itemInHand
ItemStack itemInHand(HandType handType)
Gets the equipped item in hand.- Parameters:
handType
- The hand type to retrieve from- Returns:
- The item in hand, if available
-
setItemInHand
default void setItemInHand(java.util.function.Supplier<? extends HandType> handType, ItemStack itemInHand)
Sets the equipped item in hand.- Parameters:
handType
- The hand type to set toitemInHand
- The item in hand
-
-