Package net.citizensnpcs.utils.InventoryUtils

Examples of net.citizensnpcs.utils.InventoryUtils.Armor


                if (npc.getItemInHand().getType() != Material.AIR) {
                    toAdd.add(items.get(0).createStack());
                }
                items.set(0, new ItemData(hand.getTypeId(), hand.getDurability()));
            } else {
                Armor armor = Armor.getArmorSlot(itemID);
                if (armor != null) {
                    ItemStack armorItem = armor.get(npcInv);
                    if (armorItem != null && armorItem.getType() == Material.getMaterial(itemID)) {
                        Messaging.sendError(player, error);
                        return;
                    }
                    slot = armor.name().toLowerCase();
                    if (armorItem != null && armorItem.getType() != Material.AIR) {
                        toAdd.add(items.get(armor.getSlot() + 1).createStack());
                    }
                    items.set(armor.getSlot() + 1, new ItemData(hand.getTypeId(), hand.getDurability()));
                } else {
                    if (Material.getMaterial(items.get(0).getID()) == Material.getMaterial(itemID)) {
                        Messaging.sendError(player, error);
                        return;
                    }
View Full Code Here

TOP

Related Classes of net.citizensnpcs.utils.InventoryUtils.Armor

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.