Package tconstruct.armor.items

Examples of tconstruct.armor.items.TravelGear


    @Override
    protected boolean canModify (ItemStack input, ItemStack[] recipe)
    {
        if (input.getItem() instanceof TravelGear)
        {
            TravelGear gear = (TravelGear) input.getItem();
            NBTTagCompound tags = input.getTagCompound().getCompoundTag(gear.getBaseTagName());
            int damage = tags.getInteger("Damage");
            if (damage > 0)
            {
                boolean validOutput = true;
                int outputs = 0;
                for (ItemStack curInput : recipe)
                {
                    if (curInput == null)
                        continue;

                    if (areItemStacksEquivalent(curInput, gear.getRepairMaterial(input)))
                        outputs++;
                    else
                        validOutput = false;
                }
                return validOutput && outputs > 0;
View Full Code Here


    }

    @Override
    public void modify (ItemStack[] recipe, ItemStack input)
    {
        TravelGear gear = (TravelGear) input.getItem();
        NBTTagCompound tags = input.getTagCompound().getCompoundTag(gear.getBaseTagName());
        tags.setBoolean("Broken", false);
        int damage = tags.getInteger("Damage");
        int dur = tags.getInteger("BaseDurability");
        int itemsUsed = 0;
View Full Code Here

TOP

Related Classes of tconstruct.armor.items.TravelGear

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.