Posted July 14, 201312 yr Hello, I have updated my mod(s) to 1.6.2 and did the "mods > assets" thing. But the only thing that doesn't render correctly is the armor. These are my codes: Mainclass package assets.amethysttools.common; import assets.amethysttools.common.AmethystArmor; import net.minecraft.block.Block; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.EnumArmorMaterial; import net.minecraft.item.EnumToolMaterial; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import cpw.mods.fml.common.Mod; import cpw.mods.fml.common.Mod.EventHandler; import cpw.mods.fml.common.Mod.Init; import cpw.mods.fml.common.Mod.Instance; import cpw.mods.fml.common.Mod.PreInit; import cpw.mods.fml.common.SidedProxy; import cpw.mods.fml.common.event.FMLInitializationEvent; import cpw.mods.fml.common.event.FMLPreInitializationEvent; import cpw.mods.fml.common.network.NetworkMod; import cpw.mods.fml.common.registry.GameRegistry; import cpw.mods.fml.common.registry.LanguageRegistry; import net.minecraftforge.common.EnumHelper; import net.minecraftforge.common.MinecraftForge; @Mod(modid = "amethysttools", name = "amethyst tools", version = "1.0") @NetworkMod(clientSideRequired = true, serverSideRequired = false, channels = {"AmethystTools"}, packetHandler = AmethystPacketHandler.class) public class Mainclass { public final static EnumToolMaterial AMETHYST = EnumHelper.addToolMaterial("AMETHYST", 5, 5000, 25.0F, 16, 10); public final static EnumArmorMaterial AMETHYSTARMOR = EnumHelper.addArmorMaterial("amethyst", 70, new int[]{4, 9, 5, 2}, 50); public static Item AmethystPickaxe; public static Item AmethystSword; public static Item AmethystAxe; public static Item AmethystShovel; public static Item AmethystHoe; public static Item AmethystHelm; public static Item AmethystChest; public static Item AmethystLegs; public static Item AmethystBoots; public static Item Amethyst; public static Item DiamondQuartz; public static Item RedEmerald; public static Block AmethystBlock; public static Item AmethystHorseArmor; @SidedProxy(clientSide = "assets.amethysttools.client.ClientProxy", serverSide = "assets.amethysttools.common.CommonProxy") public static CommonProxy Proxy; @Instance public static Mainclass instance = new Mainclass(); @PreInit public void PreInit(FMLPreInitializationEvent event) { AmethystPickaxe = new AmethystPickaxe(6327, AMETHYST).setMaxStackSize(1).setUnlocalizedName("amethystpickaxe").setCreativeTab(AmethystTab); AmethystSword = new AmethystSword(6326, AMETHYST).setMaxStackSize(1).setUnlocalizedName("amethystsword").setCreativeTab(AmethystTab); AmethystAxe = new AmethystAxe(6328, AMETHYST).setMaxStackSize(1).setUnlocalizedName("amethystaxe").setCreativeTab(AmethystTab); AmethystShovel = new AmethystShovel(6329, AMETHYST).setMaxStackSize(1).setUnlocalizedName("amethystshovel").setCreativeTab(AmethystTab); AmethystHoe = new AmethystHoe(6330, AMETHYST).setMaxStackSize(1).setUnlocalizedName("amethysthoe").setCreativeTab(AmethystTab); AmethystHelm = new AmethystArmor(6451, AMETHYSTARMOR, 1, 0).setMaxStackSize(1).setUnlocalizedName("amethysthelmet").setCreativeTab(AmethystTab); AmethystChest = new AmethystArmor(6452, AMETHYSTARMOR, 1, 1).setMaxStackSize(1).setUnlocalizedName("amethystchestplate").setCreativeTab(AmethystTab); AmethystLegs = new AmethystArmor(6453, AMETHYSTARMOR, 1, 2).setMaxStackSize(1).setUnlocalizedName("amethystpants").setCreativeTab(AmethystTab); AmethystBoots = new AmethystArmor(6454, AMETHYSTARMOR, 1, 3).setMaxStackSize(1).setUnlocalizedName("amethystboots").setCreativeTab(AmethystTab); Amethyst = new Amethyst(6325).setUnlocalizedName("amethyst").setCreativeTab(AmethystTab); DiamondQuartz = new DiamondQuartz(6477).setUnlocalizedName("diamondquartz").setCreativeTab(AmethystTab); AmethystBlock = new AmethystBlock(4061).setHardness(5.0F).setResistance(10.0F).setUnlocalizedName("amethystblock").setCreativeTab(AmethystTab); RedEmerald = new RedEmerald(6455).setUnlocalizedName("redemerald").setCreativeTab(AmethystTab); AmethystHorseArmor = new AmethystHorseArmor(6456).setUnlocalizedName("amethyst_horse_armor").setCreativeTab(AmethystTab); LanguageRegistry.instance().addStringLocalization("itemGroup.AmethystTab", "en_US", "Amethyst Tools"); GameRegistry.registerBlock(AmethystBlock, "Amethyst.AmethystBlock"); MinecraftForge.setBlockHarvestLevel(AmethystBlock, "pickaxe", 2); LanguageRegistry.addName(AmethystSword, "Amethyst Sword"); LanguageRegistry.addName(AmethystPickaxe, "Amethyst Pickaxe"); LanguageRegistry.addName(AmethystAxe, "Amethyst Axe"); LanguageRegistry.addName(AmethystShovel, "Amethyst Shovel"); LanguageRegistry.addName(AmethystHoe, "Amethyst Hoe"); LanguageRegistry.addName(AmethystHelm, "Amethyst Helmet"); LanguageRegistry.addName(AmethystChest, "Amethyst Chestplate"); LanguageRegistry.addName(AmethystLegs, "Amethyst Leggings"); LanguageRegistry.addName(AmethystBoots, "Amethyst Boots"); LanguageRegistry.addName(DiamondQuartz, "Diamond Quartz"); LanguageRegistry.addName(Amethyst, "Amethyst"); LanguageRegistry.addName(AmethystBlock, "Amethyst Block"); LanguageRegistry.addName(RedEmerald, "Red Emerald"); LanguageRegistry.addName(AmethystHorseArmor, "Amethyst Horse Armor"); ItemStack ame = new ItemStack(Amethyst); ItemStack stick = new ItemStack(Item.stick); ItemStack diq = new ItemStack(DiamondQuartz); ItemStack red = new ItemStack(RedEmerald); ItemStack ema = new ItemStack(Item.emerald); ItemStack dye = new ItemStack(Item.dyePowder, 1, 1); GameRegistry.addRecipe(new ItemStack (AmethystSword), "e", "e", "s", 's', stick, 'e', ame); GameRegistry.addRecipe(new ItemStack (AmethystPickaxe), "eee", " s ", " s ", 's', stick, 'e', ame); GameRegistry.addRecipe(new ItemStack (AmethystAxe), "ee ", "es ", " s ", 's', stick, 'e', ame); GameRegistry.addRecipe(new ItemStack (AmethystShovel), " e ", " s ", " s ", 's', stick, 'e', ame); GameRegistry.addRecipe(new ItemStack (AmethystHoe), "ee ", " s ", " s ", 's', stick, 'e', ame); GameRegistry.addRecipe(new ItemStack (AmethystHelm), "eee", "e e", " ", 'e', ame); GameRegistry.addRecipe(new ItemStack (AmethystHelm), " ", "eee", "e e", 'e', ame); GameRegistry.addRecipe(new ItemStack (AmethystChest), "e e", "eee", "eee", 'e', ame); GameRegistry.addRecipe(new ItemStack (AmethystLegs), "eee", "e e", "e e", 'e', ame); GameRegistry.addRecipe(new ItemStack (AmethystBoots), "e e", "e e", " ", 'e', ame); GameRegistry.addRecipe(new ItemStack (AmethystBoots), " ", "e e", "e e", 'e', ame); GameRegistry.addRecipe(new ItemStack (Amethyst), " e ", "eqe", " e ", 'e', diq, 'q', red); GameRegistry.addRecipe(new ItemStack (AmethystBlock), "aaa", "aaa", "aaa", 'a', ame); GameRegistry.addRecipe(new ItemStack(RedEmerald), " e ", "ere", " e ", 'e', ema, 'r', dye); GameRegistry.addShapelessRecipe(new ItemStack(DiamondQuartz), new Object[]{ new ItemStack(Item.diamond), new ItemStack(Item.netherQuartz) }); GameRegistry.addShapelessRecipe(new ItemStack(Amethyst, 9), new Object[]{ new ItemStack(AmethystBlock) }); } public static CreativeTabs AmethystTab = new CreativeTabs("AmethystTab") { public ItemStack getIconItemStack() { return new ItemStack(AmethystSword, 1, 0); } }; } Armor class package assets.amethysttools.common; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.entity.Entity; import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.EnumArmorMaterial; import net.minecraft.item.ItemArmor; import net.minecraft.item.ItemStack; import net.minecraft.util.DamageSource; public class AmethystArmor extends ItemArmor { public AmethystArmor(int i, EnumArmorMaterial enumarmormaterial, int j, int k) { super(i, enumarmormaterial, j, k); } @Override public void registerIcons(IconRegister iconRegister) { if(itemID == Mainclass.AmethystHelm.itemID) { itemIcon = iconRegister.registerIcon("AmethystTools:amethysthelmet"); } if(itemID == Mainclass.AmethystChest.itemID) { itemIcon = iconRegister.registerIcon("AmethystTools:amethystchestplate"); } if(itemID == Mainclass.AmethystLegs.itemID) { itemIcon = iconRegister.registerIcon("AmethystTools:amethystpants"); } if(itemID == Mainclass.AmethystBoots.itemID) { itemIcon = iconRegister.registerIcon("AmethystTools:amethystboots"); } } @Override public String getArmorTexture(ItemStack stack, Entity entity, int slot, int layer) { if(itemID == Mainclass.AmethystHelm.itemID || itemID == Mainclass.AmethystChest.itemID || itemID == Mainclass.AmethystBoots.itemID) { return CommonProxy.AMETHYST_1; } if(itemID == Mainclass.AmethystLegs.itemID) { return CommonProxy.AMETHYST_2; } else return null; } public boolean getIsRepairable(ItemStack par1ItemStack, ItemStack par2ItemStack) { return Mainclass.Amethyst.itemID == par2ItemStack.itemID ? true : super.getIsRepairable(par1ItemStack, par2ItemStack); } } Commonproxy: package assets.amethysttools.common; public class CommonProxy { public void registerRendering() { } public static String AMETHYST_1 = "/assets/amethysttools/textures/armor/amethyst_1"; public static String AMETHYST_2 = "/assets/amethysttools/textures/armor/amethyst_2.png"; } Thanks already
July 16, 201312 yr I am in the same boat you are, I cant figure out where in the heck to put the armor textures to get them to work, or how to set the path to where they ARE at. Its driving me buggy trying to figure this out.
July 16, 201312 yr Change "AmethystTools" in your armour class to "amethysttools" Also, change public static String AMETHYST_1 = "/assets/amethysttools/textures/armor/amethyst_1"; public static String AMETHYST_2 = "/assets/amethysttools/textures/armor/amethyst_2.png"; to public static String AMETHYST_1 = "amethysttools:armor/amethyst_1"; public static String AMETHYST_2 = "amethysttools:armor/amethyst_2.png"; Try that and let me know if it doesn't work http://i.imgur.com/gWwyMMO.jpg[/img]
July 16, 201312 yr Author Change "AmethystTools" in your armour class to "amethysttools" Also, change public static String AMETHYST_1 = "/assets/amethysttools/textures/armor/amethyst_1"; public static String AMETHYST_2 = "/assets/amethysttools/textures/armor/amethyst_2.png"; to public static String AMETHYST_1 = "amethysttools:armor/amethyst_1"; public static String AMETHYST_2 = "amethysttools:armor/amethyst_2.png"; Try that and let me know if it doesn't work Nope, still the same as before
July 16, 201312 yr My bad, it should've been amethysttools:textures/armor/amethyst_1 and amethysttools:textures/armor/amethyst_2 http://i.imgur.com/gWwyMMO.jpg[/img]
July 17, 201312 yr Author My bad, it should've been amethysttools:textures/armor/amethyst_1 and amethysttools:textures/armor/amethyst_2 That worked, but I had to put .png after _1/_2
July 17, 201312 yr Yeah you gotta do that. I forgot to mention that. Glad you figured it out on your own http://i.imgur.com/gWwyMMO.jpg[/img]
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.