Posted March 1, 201510 yr Hey everybody, I'm new to the forge api and I'm hoping to get some pointers and an idea of the basics (so I can go from there). I've spent some time perusing the minecraft code after decompiling it through MCP so I'm slightly familiar with it. I have everything set up in eclipse and ready to go (as far as I know). Also I have a (mostly) solid understanding of java, so really I'm just hoping to get started with a couple simple things, such as adding an item (I went through the tutorial on the forum, which is outdated for 1.8 ). How does the constructor class for an item make the super call? Following the wiki tutorial I get an error telling me the super call for Item() can take no arguments. How is the item given an ID when constructed? Thanks for any help/tips.
March 1, 201510 yr Hi You might find the topics on this page useful http://greyminecraftcoder.blogspot.com.au/p/list-of-topics.html Also this example project https://github.com/TheGreyGhost/MinecraftByExample Short answer to your question: Items don't use explicit IDs any more. They are inserted into a registry which takes care of ID numbers and such. They have names instead. For example GameRegistry.registerItem(itemSimple, "mbe10_item_simple"); For a simple item example, see here https://github.com/TheGreyGhost/MinecraftByExample/tree/master/src/main/java/minecraftbyexample/mbe10_item_simple -TGG
March 2, 201510 yr Author Thanks for the helpful reply. And that sounds much better than individual IDs.
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.