From a11c98c6cad501e081837ec8fa2e323edaeb1ca3 Mon Sep 17 00:00:00 2001 From: bculkin2442 Date: Thu, 24 May 2018 15:52:43 -0400 Subject: Initial commit --- TF2 Crates/src/main/java/baubles/api/IBauble.java | 48 +++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100755 TF2 Crates/src/main/java/baubles/api/IBauble.java (limited to 'TF2 Crates/src/main/java/baubles/api/IBauble.java') diff --git a/TF2 Crates/src/main/java/baubles/api/IBauble.java b/TF2 Crates/src/main/java/baubles/api/IBauble.java new file mode 100755 index 0000000..bbf1d19 --- /dev/null +++ b/TF2 Crates/src/main/java/baubles/api/IBauble.java @@ -0,0 +1,48 @@ +package baubles.api; + +import net.minecraft.entity.EntityLivingBase; +import net.minecraft.item.ItemStack; + +/** + * + * This interface should be extended by items that can be worn in bauble + * slots + * + * @author Azanor + */ + +public interface IBauble { + + /** + * This method return the type of bauble this is. Type is used to + * determine the slots it can go into. + */ + public BaubleType getBaubleType(ItemStack itemstack); + + /** + * This method is called once per tick if the bauble is being worn by a + * player + */ + public void onWornTick(ItemStack itemstack, EntityLivingBase player); + + /** + * This method is called when the bauble is equipped by a player + */ + public void onEquipped(ItemStack itemstack, EntityLivingBase player); + + /** + * This method is called when the bauble is unequipped by a player + */ + public void onUnequipped(ItemStack itemstack, EntityLivingBase player); + + /** + * can this bauble be placed in a bauble slot + */ + public boolean canEquip(ItemStack itemstack, EntityLivingBase player); + + /** + * Can this bauble be removed from a bauble slot + */ + public boolean canUnequip(ItemStack itemstack, + EntityLivingBase player); +} -- cgit v1.2.3