SHARE
TWEET

ItemMod

a guest May 3rd, 2019 106 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package com.novatech.mod.init;
  2.  
  3. import com.novatech.mod.Reference;
  4. import com.novatech.mod.Axe.Axe;
  5. import com.novatech.mod.Pickaxe.Pickaxe;
  6. import com.novatech.mod.ShovelD.Shovel;
  7. import com.novatech.mod.items.Armor;
  8. import com.novatech.mod.items.ItemSeedsMod;
  9. import com.novatech.mod.items.Sword;
  10.  
  11. import cpw.mods.fml.common.registry.GameRegistry;
  12. import net.minecraft.creativetab.CreativeTabs;
  13. import net.minecraft.init.Blocks;
  14. import net.minecraft.init.Items;
  15. import net.minecraft.item.Item;
  16. import net.minecraft.item.Item.ToolMaterial;
  17. import net.minecraft.item.ItemArmor.ArmorMaterial;
  18. import net.minecraft.item.ItemStack;
  19. import net.minecraftforge.common.util.EnumHelper;
  20.  
  21. public class ItemMod {
  22.    
  23.     public static ToolMaterial nikraniumMaterial = EnumHelper.addToolMaterial("nikraniumMeterial", 3, 1600, 5, 6, 25);
  24.     //                                                                        name  HarvestLevel  MaxUses  efficiency  damage  enchantability
  25.     public static ArmorMaterial nikraniumArmorMaterial = EnumHelper.addArmorMaterial("ArmorMaterial", 35, new int[] {2, 5, 4, 2}, 25);
  26.    
  27.     public static Item angelicRing;
  28.     public static Item nikraniumIngot;
  29.     public static Item nikraniumSword;
  30.     public static Item nikraniumPickaxe;
  31.     public static Item nikraniumAxe;
  32.     public static Item nikraniumShovel;
  33.     public static Item nikraniumHelmet;
  34.     public static Item nikraniumChestplate;
  35.     public static Item nikraniumLeggings;
  36.     public static Item nikraniumBoots;
  37.     public static Item nikraniumSeeds;
  38.    
  39.     public static void init() {
  40.  
  41.         angelicRing = new Item().setCreativeTab(CreativeTabs.tabMisc).setUnlocalizedName("angelicRing").setTextureName(Reference.MOD_ID + ":angelicRing");
  42.         nikraniumIngot = new Item().setCreativeTab(CreativeTabs.tabMisc).setUnlocalizedName("nikraniumIngot").setTextureName(Reference.MOD_ID + ":nikraniumIngot");
  43.        
  44.         nikraniumSword = new Sword(ItemMod.nikraniumMaterial).setCreativeTab(CreativeTabs.tabTools).setTextureName(Reference.MOD_ID + ":nikraniumSword").setUnlocalizedName("nikraniumSword");
  45.         nikraniumPickaxe = new Pickaxe(ItemMod.nikraniumMaterial).setCreativeTab(CreativeTabs.tabTools).setTextureName(Reference.MOD_ID + ":nikraniumPickaxe").setUnlocalizedName("nikraniumPickaxe");
  46.         nikraniumAxe = new Axe(ItemMod.nikraniumMaterial).setCreativeTab(CreativeTabs.tabTools).setTextureName(Reference.MOD_ID + ":nikraniumAxe").setUnlocalizedName("nikraniumAxe");
  47.         nikraniumShovel = new Shovel(ItemMod.nikraniumMaterial).setCreativeTab(CreativeTabs.tabTools).setTextureName(Reference.MOD_ID + ":nikraniumShovel").setUnlocalizedName("nikraniumShovel");
  48.         nikraniumHelmet = new Armor(nikraniumArmorMaterial, 0).setCreativeTab(CreativeTabs.tabCombat).setTextureName(Reference.MOD_ID + ":nikraniumHelmet").setUnlocalizedName("nikraniumHelmet");
  49.         nikraniumChestplate = new Armor(nikraniumArmorMaterial, 1).setCreativeTab(CreativeTabs.tabCombat).setTextureName(Reference.MOD_ID + ":nikraniumChestplate").setUnlocalizedName("nikraniumChestplate");
  50.         nikraniumLeggings = new Armor(nikraniumArmorMaterial, 2).setCreativeTab(CreativeTabs.tabCombat).setTextureName(Reference.MOD_ID + ":nikraniumLeggings").setUnlocalizedName("nikraniumLeggings");
  51.         nikraniumBoots = new Armor(nikraniumArmorMaterial, 3).setCreativeTab(CreativeTabs.tabCombat).setTextureName(Reference.MOD_ID + ":nikraniumBoots").setUnlocalizedName("nikraniumBoots");
  52.         nikraniumSeeds = new ItemSeedsMod(BlocksMod.nikraniumCrop, Blocks.farmland).setCreativeTab(CreativeTabs.tabMisc).setUnlocalizedName("nikraniumSeeds").setTextureName(Reference.MOD_ID + ":nikraniumSeeds");
  53.     }
  54.    
  55.     public static void register() {
  56.         GameRegistry.registerItem(angelicRing, "angelicRing");
  57.         GameRegistry.registerItem(nikraniumIngot, "nikraniumIngot");
  58.         GameRegistry.registerItem(nikraniumSword, "nikraniumSword");
  59.         GameRegistry.registerItem(nikraniumPickaxe, "nikraniumPickaxe");
  60.         GameRegistry.registerItem(nikraniumAxe, "nikraniumAxe");
  61.         GameRegistry.registerItem(nikraniumShovel, "nikraniumShovel");
  62.         GameRegistry.registerItem(nikraniumHelmet, "nikraniumHelmet");
  63.         GameRegistry.registerItem(nikraniumChestplate, "nikraniumChestplate");
  64.         GameRegistry.registerItem(nikraniumLeggings, "nikraniumLeggings");
  65.         GameRegistry.registerItem(nikraniumBoots, "nikraniumBoots");
  66.         GameRegistry.registerItem(nikraniumSeeds, "nikraniumSeeds");
  67.        
  68.         GameRegistry.addRecipe(new ItemStack(ItemMod.nikraniumSword, 1), new Object[] {"  I", "  I", "  S", 'I', ItemMod.nikraniumIngot, 'S', Items.stick});
  69.         GameRegistry.addRecipe(new ItemStack(ItemMod.nikraniumSword, 1), new Object[] {" I ", " I ", " S ", 'I', ItemMod.nikraniumIngot, 'S', Items.stick});
  70.         GameRegistry.addRecipe(new ItemStack(ItemMod.nikraniumSword, 1), new Object[] {"I  ", "I  ", "S  ", 'I', ItemMod.nikraniumIngot, 'S', Items.stick});
  71.         GameRegistry.addRecipe(new ItemStack(ItemMod.nikraniumPickaxe, 1), new Object[] {"III", " S ", " S ", 'I', ItemMod.nikraniumIngot, 'S', Items.stick});
  72.         GameRegistry.addRecipe(new ItemStack(ItemMod.nikraniumAxe, 1), new Object[] {" II", " SI", " S ", 'I', ItemMod.nikraniumIngot, 'S', Items.stick});
  73.         GameRegistry.addRecipe(new ItemStack(ItemMod.nikraniumAxe, 1), new Object[] {"II ", "IS ", " S ", 'I', ItemMod.nikraniumIngot, 'S', Items.stick});
  74.         GameRegistry.addRecipe(new ItemStack(ItemMod.nikraniumShovel, 1), new Object[] {"  I", "  S", "  S", 'I', ItemMod.nikraniumIngot, 'S', Items.stick});
  75.         GameRegistry.addRecipe(new ItemStack(ItemMod.nikraniumShovel, 1), new Object[] {" I ", " S ", " S ", 'I', ItemMod.nikraniumIngot, 'S', Items.stick});
  76.         GameRegistry.addRecipe(new ItemStack(ItemMod.nikraniumShovel, 1), new Object[] {"I  ", "S  ", "S  ", 'I', ItemMod.nikraniumIngot, 'S', Items.stick});
  77.        
  78.     }
  79.    
  80. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top