Advertisement
Guest User

ArmorHandler.java

a guest
Mar 2nd, 2014
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 5.91 KB | None | 0 0
  1. package nxs.minextension.core;
  2.  
  3. import net.minecraft.item.ItemArmor;
  4. import net.minecraft.item.ItemArmor.ArmorMaterial;
  5. import net.minecraftforge.common.util.EnumHelper;
  6. import nxs.minextension.item.armor.AmethystArmor;
  7. import nxs.minextension.item.armor.CopperArmor;
  8. import nxs.minextension.item.armor.OnyxArmor;
  9. import nxs.minextension.item.armor.PlatinumArmor;
  10. import nxs.minextension.item.armor.RubyArmor;
  11. import nxs.minextension.item.armor.SapphireArmor;
  12. import project.api.item.armor.APIArmor;
  13. import cpw.mods.fml.common.registry.GameRegistry;
  14.  
  15. public class ArmorHandler {
  16.  
  17.     public static ArmorMaterial copper = EnumHelper.addArmorMaterial("copper", 55, new int[] { 3, 5, 4, 3 }, 20);
  18.     public static ArmorMaterial platinum = EnumHelper.addArmorMaterial("platinum", 85, new int[] { 4, 5, 4, 3 }, 30);
  19.     public static ArmorMaterial ruby = EnumHelper.addArmorMaterial("ruby", 250, new int[] { 5, 6, 5, 4 }, 35);
  20.     public static ArmorMaterial sapphire = EnumHelper.addArmorMaterial("sapphire", 400, new int[] { 6, 7, 6, 5 }, 40);
  21.     public static ArmorMaterial onyx = EnumHelper.addArmorMaterial("onyx", 1200, new int[] { 7, 8, 7, 6 }, 50);
  22.     public static ArmorMaterial mythril = EnumHelper.addArmorMaterial("mythril", 600, new int[] { 8, 9, 8, 7 }, 55);
  23.     public static ArmorMaterial amethyst = EnumHelper.addArmorMaterial("amethyst", 1000, new int[] { 10, 11, 10, 9 }, 64);
  24.  
  25.     public static ItemArmor copper_helmet, copper_chestplate, copper_leggings, copper_boots;
  26.     public static ItemArmor platinum_helmet, platinum_chestplate, platinum_leggings, platinum_boots;
  27.     public static ItemArmor ruby_helmet, ruby_chestplate, ruby_leggings, ruby_boots;
  28.     public static ItemArmor sapphire_helmet, sapphire_chestplate, sapphire_leggings, sapphire_boots;
  29.     public static ItemArmor onyx_helmet, onyx_chestplate, onyx_leggings, onyx_boots;
  30.     public static ItemArmor amethyst_helmet, amethyst_chestplate, amethyst_leggings, amethyst_boots;
  31.  
  32.     public static void addArmors() {
  33.         copper_helmet = new CopperArmor(copper, 0, 0).setNameAndTab("copperHelmet", TabHandler.nxsTab);
  34.         copper_chestplate = new CopperArmor(copper, 1, 1).setNameAndTab("copperChestplate", TabHandler.nxsTab);
  35.         copper_leggings = new CopperArmor(copper, 2, 2).setNameAndTab("copperLeggings", TabHandler.nxsTab);
  36.         copper_boots = new CopperArmor(copper, 3, 3).setNameAndTab("copperBoots", TabHandler.nxsTab);
  37.         platinum_helmet = new PlatinumArmor(platinum, 0, 0).setNameAndTab("platinumHelmet", TabHandler.nxsTab);
  38.         platinum_chestplate = new PlatinumArmor(platinum, 1, 1).setNameAndTab("platinumChestplate", TabHandler.nxsTab);
  39.         platinum_leggings = new PlatinumArmor(platinum, 2, 2).setNameAndTab("platinumLeggings", TabHandler.nxsTab);
  40.         platinum_boots = new PlatinumArmor(platinum, 3, 3).setNameAndTab("platinumBoots", TabHandler.nxsTab);
  41.         ruby_helmet = new RubyArmor(ruby, 0, 0).setNameAndTab("rubyHelmet", TabHandler.nxsTab);
  42.         ruby_chestplate = new RubyArmor(ruby, 1, 1).setNameAndTab("rubyChestplate", TabHandler.nxsTab);
  43.         ruby_leggings = new RubyArmor(ruby, 2, 2).setNameAndTab("rubyLeggings", TabHandler.nxsTab);
  44.         ruby_boots = new RubyArmor(ruby, 3, 3).setNameAndTab("rubyBoots", TabHandler.nxsTab);
  45.         sapphire_helmet = new SapphireArmor(sapphire, 0, 0).setNameAndTab("sapphireHelmet", TabHandler.nxsTab);
  46.         sapphire_chestplate = new SapphireArmor(sapphire, 1, 1).setNameAndTab("sapphireChestplate", TabHandler.nxsTab);
  47.         sapphire_leggings = new SapphireArmor(sapphire, 2, 2).setNameAndTab("sapphireLeggings", TabHandler.nxsTab);
  48.         sapphire_boots = new SapphireArmor(sapphire, 3, 3).setNameAndTab("sapphireBoots", TabHandler.nxsTab);
  49.         onyx_helmet = new OnyxArmor(onyx, 0, 0).setNameAndTab("onyxHelmet", TabHandler.nxsTab);
  50.         onyx_chestplate = new OnyxArmor(onyx, 1, 1).setNameAndTab("onyxChestplate", TabHandler.nxsTab);
  51.         onyx_leggings = new OnyxArmor(onyx, 2, 2).setNameAndTab("onyxLeggings", TabHandler.nxsTab);
  52.         onyx_boots = new OnyxArmor(onyx, 3, 3).setNameAndTab("onyxBoots", TabHandler.nxsTab);
  53.         amethyst_helmet = new AmethystArmor(amethyst, 0, 0).setNameAndTab("amethystHelmet", TabHandler.nxsTab);
  54.         amethyst_chestplate = new AmethystArmor(amethyst, 1, 1).setNameAndTab("amethystChestplate", TabHandler.nxsTab);
  55.         amethyst_leggings = new AmethystArmor(amethyst, 2, 2).setNameAndTab("amethystLeggings", TabHandler.nxsTab);
  56.         amethyst_boots = new AmethystArmor(amethyst, 3, 3).setNameAndTab("amethystBoots", TabHandler.nxsTab);
  57.     }
  58.  
  59.     public static void registerArmors() {
  60.         GameRegistry.registerItem(copper_helmet, "copperHelmet");
  61.         GameRegistry.registerItem(copper_chestplate, "copperChestplate");
  62.         GameRegistry.registerItem(copper_leggings, "copperLeggings");
  63.         GameRegistry.registerItem(copper_boots, "copperBoots");
  64.         GameRegistry.registerItem(platinum_helmet, "platinumHelmet");
  65.         GameRegistry.registerItem(platinum_chestplate, "platinumChestplate");
  66.         GameRegistry.registerItem(platinum_leggings, "platinumLeggings");
  67.         GameRegistry.registerItem(platinum_boots, "platinumBoots");
  68.         GameRegistry.registerItem(ruby_helmet, "rubyHelmet");
  69.         GameRegistry.registerItem(ruby_chestplate, "rubyChestplate");
  70.         GameRegistry.registerItem(ruby_leggings, "rubyLeggings");
  71.         GameRegistry.registerItem(ruby_boots, "rubyBoots");
  72.         GameRegistry.registerItem(sapphire_helmet, "sapphireHelmet");
  73.         GameRegistry.registerItem(sapphire_chestplate, "sapphireChestplate");
  74.         GameRegistry.registerItem(sapphire_leggings, "sapphireLeggings");
  75.         GameRegistry.registerItem(sapphire_boots, "sapphireBoots");
  76.         GameRegistry.registerItem(onyx_helmet, "onyxHelmet");
  77.         GameRegistry.registerItem(onyx_chestplate, "onyxChestplate");
  78.         GameRegistry.registerItem(onyx_leggings, "onyxLeggings");
  79.         GameRegistry.registerItem(onyx_boots, "onyxBoots");
  80.         GameRegistry.registerItem(amethyst_helmet, "amethystHelmet");
  81.         GameRegistry.registerItem(amethyst_chestplate, "amethystChestplate");
  82.         GameRegistry.registerItem(amethyst_leggings, "amethystLeggings");
  83.         GameRegistry.registerItem(amethyst_boots, "amethystBoots");
  84.     }
  85. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement