// Path: src/main/java/matgm50/twarden/TWarden.java
// @Mod(modid = ModLib.ID, name = ModLib.NAME, version = ModLib.VERSION, dependencies = ModLib.DEPENDENCIES)
// 
// public class TWarden {
// 
//     @Instance(ModLib.ID)
//     public static TWarden instance;
// 
//     @SidedProxy(serverSide = ModLib.COMMONPROXY, clientSide = ModLib.CLIENTPROXY)
//     public static CommonProxy proxy;
// 
//     public static CreativeTabs tabTWarden = new TabTWarden(ModLib.ID);
// 
//     @EventHandler
//     public void preInit(FMLPreInitializationEvent event) {
// 
//         proxy.initRenderers();
//         GuiHandler.init();
// 
//         WardenicChargeEvents.init();
//         WardenicUpgrades.init();
// 
//         ModItems.init();
//         ModBlocks.init();
//         ModEntities.init();
//         ModGen.init();
// 
//     }
// 
//     @EventHandler
//     public void init(FMLInitializationEvent event) {
// 
//     }
// 
//     @EventHandler
//     public void postInit(FMLPostInitializationEvent event) {
// 
//         ModRecipes.init();
//         ModResearch.init();
// 
//     }
// 
// }
// 
// Path: src/main/java/matgm50/twarden/lib/ItemLib.java
// public class ItemLib {
// 
//     public static final String RESOURCE_NAME = "itemResource";
//     public static final String[] RESOURCE_ICON = {"wardenpetal", "wardenstone", "wardenquartz"};
// 
//     public static final String WARDEN_AMULET_NAME = "itemWardenAmulet";
//     public static final String WARDEN_WEAPON_NAME = "itemWardenWeapon";
//     public static final String WARDEN_HELM_NAME = "itemWardenHelm";
//     public static final String WARDEN_CHEST_NAME = "itemWardenChest";
//     public static final String WARDEN_LEGS_NAME = "itemWardenLegs";
//     public static final String WARDEN_BOOTS_NAME = "itemWardenBoots";
//     public static final String PURITY_FOCUS_NAME = "itemFocusPurity";
//     public static final String LOVE_RING_NAME = "itemLoveRing";
//     public static final String WASLIE_HAMMER_NAME = "itemWaslieHammer";
//     public static final String ILLUMI_FOCUS_NAME = "itemFocusIllumination";
// 
// }
// 
// Path: src/main/java/matgm50/twarden/util/wardenic/WardenicChargeHelper.java
// public class WardenicChargeHelper {
// 
//     public static HashMap<String, WardenicUpgrade> upgrades = new HashMap<String, WardenicUpgrade>();
// 
//     public static void addUpgrade(WardenicUpgrade upgrade) {
// 
//         addUpgrade(upgrade.aspect.getName(), upgrade);
// 
//     }
// 
//     public static void addUpgrade(String key, WardenicUpgrade upgrade) {
// 
//         upgrades.put(key, upgrade);
// 
//     }
// 
//     public static WardenicUpgrade getUpgrade(ItemStack stack) {
// 
//         if(stack.stackTagCompound != null) {
// 
//             if(stack.stackTagCompound.hasKey("upgrade")) {
// 
//                 return upgrades.get(stack.stackTagCompound.getString("upgrade"));
// 
//             } else {
// 
//                 return upgrades.get(ModResearch.EXUBITOR.getName());
// 
//             }
// 
//         } else {
// 
//             return upgrades.get(ModResearch.EXUBITOR.getName());
// 
//         }
// 
//     }
// 
//     public static void setUpgradeOnStack(ItemStack stack, String key) {
// 
//         if(stack.stackTagCompound == null) {
// 
//             stack.setTagCompound(new NBTTagCompound());
// 
//         }
// 
//         stack.stackTagCompound.setString("upgrade", key);
// 
//     }
// 
// }


import matgm50.twarden.TWarden;
import matgm50.twarden.lib.ItemLib;
import matgm50.twarden.util.wardenic.WardenicChargeHelper;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.EnumRarity;
import net.minecraft.item.ItemArmor;
import net.minecraft.item.ItemStack;
import net.minecraft.util.DamageSource;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.StatCollector;
import net.minecraft.world.World;
import net.minecraftforge.common.ISpecialArmor;
import thaumcraft.api.IVisDiscountGear;
import thaumcraft.api.aspects.Aspect;
import java.util.List;
package matgm50.twarden.item;



/**
 * Created by MasterAbdoTGM50 on 6/26/2014.
 */

public class ItemWardenArmor extends ItemArmor implements ISpecialArmor, IVisDiscountGear {

    public ItemWardenArmor(int type) {

        super(ModItems.materialWarden, 3, type);
        setCreativeTab(TWarden.tabTWarden);
        setMaxStackSize(1);

    }

    @Override
    public boolean getShareTag() {return true;}

    @Override
    public boolean isBookEnchantable(ItemStack stack, ItemStack book) {return false;}

    @Override
    public int getMaxDamage(ItemStack stack) {return 50;}

    @Override
    public boolean isDamageable() {return false;}

    @Override
    public EnumRarity getRarity(ItemStack par1ItemStack) {return EnumRarity.epic;}

    @Override
    public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List, boolean par4) {

        par3List.add(EnumChatFormatting.AQUA + StatCollector.translateToLocal("tooltip.wardenic.charge") + ": " + (par1ItemStack.getMaxDamage() - par1ItemStack.getItemDamage()) + "/" + par1ItemStack.getMaxDamage());
        par3List.add(EnumChatFormatting.GOLD + StatCollector.translateToLocal("tooltip.wardenic.upgrade") + ": " + WardenicChargeHelper.getUpgrade(par1ItemStack).getQuote());

        super.addInformation(par1ItemStack, par2EntityPlayer, par3List, par4);

    }

    @Override
    public void onArmorTick(World world, EntityPlayer player, ItemStack itemStack) {

// Path: src/main/java/matgm50/twarden/TWarden.java
// @Mod(modid = ModLib.ID, name = ModLib.NAME, version = ModLib.VERSION, dependencies = ModLib.DEPENDENCIES)
// 
// public class TWarden {
// 
//     @Instance(ModLib.ID)
//     public static TWarden instance;
// 
//     @SidedProxy(serverSide = ModLib.COMMONPROXY, clientSide = ModLib.CLIENTPROXY)
//     public static CommonProxy proxy;
// 
//     public static CreativeTabs tabTWarden = new TabTWarden(ModLib.ID);
// 
//     @EventHandler
//     public void preInit(FMLPreInitializationEvent event) {
// 
//         proxy.initRenderers();
//         GuiHandler.init();
// 
//         WardenicChargeEvents.init();
//         WardenicUpgrades.init();
// 
//         ModItems.init();
//         ModBlocks.init();
//         ModEntities.init();
//         ModGen.init();
// 
//     }
// 
//     @EventHandler
//     public void init(FMLInitializationEvent event) {
// 
//     }
// 
//     @EventHandler
//     public void postInit(FMLPostInitializationEvent event) {
// 
//         ModRecipes.init();
//         ModResearch.init();
// 
//     }
// 
// }
// 
// Path: src/main/java/matgm50/twarden/lib/ItemLib.java
// public class ItemLib {
// 
//     public static final String RESOURCE_NAME = "itemResource";
//     public static final String[] RESOURCE_ICON = {"wardenpetal", "wardenstone", "wardenquartz"};
// 
//     public static final String WARDEN_AMULET_NAME = "itemWardenAmulet";
//     public static final String WARDEN_WEAPON_NAME = "itemWardenWeapon";
//     public static final String WARDEN_HELM_NAME = "itemWardenHelm";
//     public static final String WARDEN_CHEST_NAME = "itemWardenChest";
//     public static final String WARDEN_LEGS_NAME = "itemWardenLegs";
//     public static final String WARDEN_BOOTS_NAME = "itemWardenBoots";
//     public static final String PURITY_FOCUS_NAME = "itemFocusPurity";
//     public static final String LOVE_RING_NAME = "itemLoveRing";
//     public static final String WASLIE_HAMMER_NAME = "itemWaslieHammer";
//     public static final String ILLUMI_FOCUS_NAME = "itemFocusIllumination";
// 
// }
// 
// Path: src/main/java/matgm50/twarden/util/wardenic/WardenicChargeHelper.java
// public class WardenicChargeHelper {
// 
//     public static HashMap<String, WardenicUpgrade> upgrades = new HashMap<String, WardenicUpgrade>();
// 
//     public static void addUpgrade(WardenicUpgrade upgrade) {
// 
//         addUpgrade(upgrade.aspect.getName(), upgrade);
// 
//     }
// 
//     public static void addUpgrade(String key, WardenicUpgrade upgrade) {
// 
//         upgrades.put(key, upgrade);
// 
//     }
// 
//     public static WardenicUpgrade getUpgrade(ItemStack stack) {
// 
//         if(stack.stackTagCompound != null) {
// 
//             if(stack.stackTagCompound.hasKey("upgrade")) {
// 
//                 return upgrades.get(stack.stackTagCompound.getString("upgrade"));
// 
//             } else {
// 
//                 return upgrades.get(ModResearch.EXUBITOR.getName());
// 
//             }
// 
//         } else {
// 
//             return upgrades.get(ModResearch.EXUBITOR.getName());
// 
//         }
// 
//     }
// 
//     public static void setUpgradeOnStack(ItemStack stack, String key) {
// 
//         if(stack.stackTagCompound == null) {
// 
//             stack.setTagCompound(new NBTTagCompound());
// 
//         }
// 
//         stack.stackTagCompound.setString("upgrade", key);
// 
//     }
// 
// }


// Path: src/main/java/matgm50/twarden/item/ItemWardenArmor.java
import matgm50.twarden.TWarden;
import matgm50.twarden.lib.ItemLib;
import matgm50.twarden.util.wardenic.WardenicChargeHelper;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.EnumRarity;
import net.minecraft.item.ItemArmor;
import net.minecraft.item.ItemStack;
import net.minecraft.util.DamageSource;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.StatCollector;
import net.minecraft.world.World;
import net.minecraftforge.common.ISpecialArmor;
import thaumcraft.api.IVisDiscountGear;
import thaumcraft.api.aspects.Aspect;
import java.util.List;

package matgm50.twarden.item;



/**
 * Created by MasterAbdoTGM50 on 6/26/2014.
 */

public class ItemWardenArmor extends ItemArmor implements ISpecialArmor, IVisDiscountGear {

    public ItemWardenArmor(int type) {

        super(ModItems.materialWarden, 3, type);
        setCreativeTab(TWarden.tabTWarden);
        setMaxStackSize(1);

    }

    @Override
    public boolean getShareTag() {return true;}

    @Override
    public boolean isBookEnchantable(ItemStack stack, ItemStack book) {return false;}

    @Override
    public int getMaxDamage(ItemStack stack) {return 50;}

    @Override
    public boolean isDamageable() {return false;}

    @Override
    public EnumRarity getRarity(ItemStack par1ItemStack) {return EnumRarity.epic;}

    @Override
    public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List, boolean par4) {

        par3List.add(EnumChatFormatting.AQUA + StatCollector.translateToLocal("tooltip.wardenic.charge") + ": " + (par1ItemStack.getMaxDamage() - par1ItemStack.getItemDamage()) + "/" + par1ItemStack.getMaxDamage());
        par3List.add(EnumChatFormatting.GOLD + StatCollector.translateToLocal("tooltip.wardenic.upgrade") + ": " + WardenicChargeHelper.getUpgrade(par1ItemStack).getQuote());

        super.addInformation(par1ItemStack, par2EntityPlayer, par3List, par4);

    }

    @Override
    public void onArmorTick(World world, EntityPlayer player, ItemStack itemStack) {

        WardenicChargeHelper.getUpgrade(itemStack).onTick(world, player, itemStack);