Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //goes in mod.divinity.init
- package mod.divinity.init;
- import mod.divinity.Reference;
- import net.minecraft.client.Minecraft;
- import net.minecraft.client.resources.model.ModelResourceLocation;
- import net.minecraft.item.Item;
- import net.minecraftforge.fml.common.registry.GameRegistry;
- public class DivinityItems {
- public static Item tenebrium_ingot;
- public static void init() {
- tenebrium_ingot = new Item().setUnlocalizedName("tenebrium_ingot");
- }
- public static void register() {
- GameRegistry.registerItem(tenebrium_ingot, tenebrium_ingot.getUnlocalizedName().substring(5)); //"tile.testItem"
- }
- public static void registerRenders() {
- registerRender(tenebrium_ingot);
- }
- public static void registerRender(Item item) {
- Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(item, 0, new ModelResourceLocation(Reference.MOD_ID + ":" + item.getUnlocalizedName().substring(5), "inventory"));
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement