Posted December 4, 201311 yr code is package SomeCraft; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.Item; public class SomoniomIngot extends Item { public SomoniomIngot(int id) { super(id); this.setCreativeTab(CreativeTabs.tabMaterials); } public void registerIcon(IconRegister par1IconRegister) { this.itemIcon = par1IconRegister.registerIcon(SomeCraft.modid + ":" +(this.getUnlocalizedName().substring(5))); } } this is the structure i am loading from C:\Users\cole c\Documents\Folders\Modding\forge-1.6.4-9.11.1.953-src\forge\mcp\src\minecraft\assets\somecraft\textures\items and the name of the png file is SomoniomIngot
December 4, 201311 yr use all lower case letters in both your code and your file and folder names. Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable. If you think this is the case, JUST REPORT ME. Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice. Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked. DO NOT PM ME WITH PROBLEMS. No help will be given.
December 4, 201311 yr Author still not working when i was logging in to the world i created it said id mismatch 5056 but my id for my ingot is 5000
December 4, 201311 yr Author is there any other way that i can assign a texture to an item not using this line of code this.itemIcon = par1IconRegister.registerIcon(SomeCraft.modid + ":" +(this.getUnlocalizedName().substring(5))); if there is please tell me thank you fro helping me Sincerely, ClarmonkGaming
December 5, 201311 yr I believe if you're just trying to set a texture for an item, you can insert the following line of code: setTextureName("yourmodid:yourTextureName") I'm not sure if you need to make it this.setTextureName() but I don't think so. All my textures are camelCased so I have my texture name camelCased but I'm not sure it matters as long as you're consistent. Also, you can place your textures in a different location- inside the mcp folder, you can create another folder entitled res, which then contains your assets folder. EDIT: The new folder res is simply a workaround for the fact that Eclipse doesn't find textures in the proper location; if you're not using Eclipse, ignore that suggestion! However, if you are, check out the forge wiki page for Eclipse for more info. http://www.minecraftforge.net/wiki/Eclipse#Fixing_textures_not_being_copied Instead of retrieving your modID, you can just type it out. I've had textures work with a separate name from my actual modID; it didn't matter as long as I named my folder the same thing. But that might not work in multiplayer. Hopefully that works for you!
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.