Class EntityEquipmentMock
java.lang.Object
be.seeseemelk.mockbukkit.inventory.EntityEquipmentMock
- All Implemented Interfaces:
EntityEquipment
This mocks the
EntityEquipment
of a LivingEntityMock
. Note that not every LivingEntity
has
EntityEquipment
, so only implement this where necessary.-
Constructor Summary
ConstructorDescriptionEntityEquipmentMock
(@NotNull LivingEntityMock holder) Constructs a newEntityEquipmentMock
for the given holder. -
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
ItemStack @NotNull []
@NotNull ItemStack
getBoots()
float
@NotNull ItemStack
float
float
getDropChance
(@NotNull EquipmentSlot slot) @NotNull ItemStack
float
@NotNull Entity
@NotNull ItemStack
getItem
(@NotNull EquipmentSlot slot) @NotNull ItemStack
Deprecated.float
Deprecated.@NotNull ItemStack
float
@NotNull ItemStack
float
@NotNull ItemStack
float
void
setArmorContents
(@NotNull ItemStack @NotNull [] items) void
void
void
setBootsDropChance
(float chance) void
setChestplate
(@Nullable ItemStack chestplate) void
setChestplate
(@Nullable ItemStack chestplate, boolean silent) void
setChestplateDropChance
(float chance) void
setDropChance
(@NotNull EquipmentSlot slot, float chance) void
void
void
setHelmetDropChance
(float chance) void
setItem
(@NotNull EquipmentSlot slot, @Nullable ItemStack item) void
setItem
(@NotNull EquipmentSlot slot, @Nullable ItemStack item, boolean silent) void
setItemInHand
(@Nullable ItemStack stack) Deprecated.void
setItemInHandDropChance
(float chance) Deprecated.void
setItemInMainHand
(@Nullable ItemStack item) void
setItemInMainHand
(@Nullable ItemStack item, boolean silent) void
setItemInMainHandDropChance
(float chance) void
setItemInOffHand
(@Nullable ItemStack item) void
setItemInOffHand
(@Nullable ItemStack item, boolean silent) void
setItemInOffHandDropChance
(float chance) void
setLeggings
(@Nullable ItemStack leggings) void
setLeggings
(@Nullable ItemStack leggings, boolean silent) void
setLeggingsDropChance
(float chance)
-
Constructor Details
-
EntityEquipmentMock
Constructs a newEntityEquipmentMock
for the given holder.- Parameters:
holder
- The holder of the inventory.
-
-
Method Details
-
setItem
- Specified by:
setItem
in interfaceEntityEquipment
-
setItem
public void setItem(@NotNull @NotNull EquipmentSlot slot, @Nullable @Nullable ItemStack item, boolean silent) - Specified by:
setItem
in interfaceEntityEquipment
-
getItem
- Specified by:
getItem
in interfaceEntityEquipment
-
getItemInMainHand
- Specified by:
getItemInMainHand
in interfaceEntityEquipment
-
setItemInMainHand
- Specified by:
setItemInMainHand
in interfaceEntityEquipment
-
setItemInMainHand
- Specified by:
setItemInMainHand
in interfaceEntityEquipment
-
getItemInOffHand
- Specified by:
getItemInOffHand
in interfaceEntityEquipment
-
setItemInOffHand
- Specified by:
setItemInOffHand
in interfaceEntityEquipment
-
setItemInOffHand
- Specified by:
setItemInOffHand
in interfaceEntityEquipment
-
getItemInHand
Deprecated.- Specified by:
getItemInHand
in interfaceEntityEquipment
-
setItemInHand
Deprecated.- Specified by:
setItemInHand
in interfaceEntityEquipment
-
getHelmet
- Specified by:
getHelmet
in interfaceEntityEquipment
-
setHelmet
- Specified by:
setHelmet
in interfaceEntityEquipment
-
setHelmet
- Specified by:
setHelmet
in interfaceEntityEquipment
-
getChestplate
- Specified by:
getChestplate
in interfaceEntityEquipment
-
setChestplate
- Specified by:
setChestplate
in interfaceEntityEquipment
-
setChestplate
- Specified by:
setChestplate
in interfaceEntityEquipment
-
getLeggings
- Specified by:
getLeggings
in interfaceEntityEquipment
-
setLeggings
- Specified by:
setLeggings
in interfaceEntityEquipment
-
setLeggings
- Specified by:
setLeggings
in interfaceEntityEquipment
-
getBoots
- Specified by:
getBoots
in interfaceEntityEquipment
-
setBoots
- Specified by:
setBoots
in interfaceEntityEquipment
-
setBoots
- Specified by:
setBoots
in interfaceEntityEquipment
-
getArmorContents
- Specified by:
getArmorContents
in interfaceEntityEquipment
-
setArmorContents
- Specified by:
setArmorContents
in interfaceEntityEquipment
-
clear
public void clear()- Specified by:
clear
in interfaceEntityEquipment
-
getItemInHandDropChance
Deprecated.- Specified by:
getItemInHandDropChance
in interfaceEntityEquipment
-
setItemInHandDropChance
Deprecated.- Specified by:
setItemInHandDropChance
in interfaceEntityEquipment
-
getItemInMainHandDropChance
public float getItemInMainHandDropChance()- Specified by:
getItemInMainHandDropChance
in interfaceEntityEquipment
-
setItemInMainHandDropChance
public void setItemInMainHandDropChance(float chance) - Specified by:
setItemInMainHandDropChance
in interfaceEntityEquipment
-
getItemInOffHandDropChance
public float getItemInOffHandDropChance()- Specified by:
getItemInOffHandDropChance
in interfaceEntityEquipment
-
setItemInOffHandDropChance
public void setItemInOffHandDropChance(float chance) - Specified by:
setItemInOffHandDropChance
in interfaceEntityEquipment
-
getHelmetDropChance
public float getHelmetDropChance()- Specified by:
getHelmetDropChance
in interfaceEntityEquipment
-
setHelmetDropChance
public void setHelmetDropChance(float chance) - Specified by:
setHelmetDropChance
in interfaceEntityEquipment
-
getChestplateDropChance
public float getChestplateDropChance()- Specified by:
getChestplateDropChance
in interfaceEntityEquipment
-
setChestplateDropChance
public void setChestplateDropChance(float chance) - Specified by:
setChestplateDropChance
in interfaceEntityEquipment
-
getLeggingsDropChance
public float getLeggingsDropChance()- Specified by:
getLeggingsDropChance
in interfaceEntityEquipment
-
setLeggingsDropChance
public void setLeggingsDropChance(float chance) - Specified by:
setLeggingsDropChance
in interfaceEntityEquipment
-
getBootsDropChance
public float getBootsDropChance()- Specified by:
getBootsDropChance
in interfaceEntityEquipment
-
setBootsDropChance
public void setBootsDropChance(float chance) - Specified by:
setBootsDropChance
in interfaceEntityEquipment
-
getHolder
- Specified by:
getHolder
in interfaceEntityEquipment
-
setDropChance
- Specified by:
setDropChance
in interfaceEntityEquipment
-
getDropChance
- Specified by:
getDropChance
in interfaceEntityEquipment
-