Jump to content

Recommended Posts

Posted

Hey there, I am having an issue with crafting... yeah, very nooblike.

I have always avoided crafting with armours/tools, because they have always been awkward (when I have tried to do them), but I don't see why this doesn't work:

 

    if(Loader.isModLoaded("Thaumcraft")){

        Item goggles = (Item) Item.itemRegistry.getObject("Thaumcraft:ItemGoggles");

        GameRegistry.addShapelessRecipe(new ItemStack(itemRegist.visViewerS),

        new ItemStack(itemRegist.superHelmet), new ItemStack(goggles)

        );

        }

       

 

To be honest, I don't know what the thaumcraft thing actually does, I am not going to lie, I copied it from a different mod which does the exact same crafting recipe I am trying to do, and it works there.

However, when I try to combine the Goggles of Revealing (Thaumcraft:ItemGoggles) and superHelmet it doesn't allow me to craft the visViewerS

 

 

 

The code I copied:

 

 

Item goggles = (Item) Item.itemRegistry.getObject("Thaumcraft:ItemGoggles");

GameRegistry.addShapelessRecipe(new ItemStack(ModItems.manasteelHelmRevealing), new ItemStack(ModItems.manasteelHelm), new ItemStack(goggles));

 

 

Why bother?

Posted

If you copied working code from another mod, I don't see why it wouldn't work. Maybe try adding a System.out.println("test") after checking if Thaumcraft is loaded, just to make sure the recipe is actually being added.

Potato's have skin. I have skin. Therefore, i am a potato.

 

Follow me on Twitter!

http://www.twitter.com/I_Mod_Minecraft

Posted

Just a quick quick Question have you registered the recipes and all the BS?

@EventHandler
   public void preInit(FMLInitializationEvent event){
	log.info("Mod Load pre run started");
                //name of you recipes class  . whatever your Init funtion for recipes is called ();
    	        Recipes.initShaplessRecipes();
}

Posted

Just a quick quick Question have you registered the recipes and all the BS?

@EventHandler
   public void preInit(FMLInitializationEvent event){
	log.info("Mod Load pre run started");
                //name of you recipes class  . whatever your Init funtion for recipes is called ();
    	        Recipes.initShaplessRecipes();
}

Here's the full class file, where everything but that one recipe works:

http://pastebin.com/mupfHBNk

The Thaumcraft recipe starts at line 122

 

Sorry for the code being very ugly

Why bother?

Posted

Does your mod get loaded after the Thaumcraft mod loaded?

You should make your mod loaded after Thaumcraft if you want to add the recipe on the preInit.

I. Stellarium for Minecraft: Configurable Universe for Minecraft! (WIP)

II. Stellar Sky, Better Star Rendering&Sky Utility mod, had separated from Stellarium.

Posted

Does your mod get loaded after the Thaumcraft mod loaded?

You should make your mod loaded after Thaumcraft if you want to add the recipe on the preInit.

How would I do that, other than calling the jar zName or change thaumcraft to aThaumcraft?

Why bother?

Posted

Add the recipies in

FMLInitializationEvent

, that way all the Items (including Thaumcraft's) are loaded, so you can use them in recipies.

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.