Jump to content

Recommended Posts

Posted

Hello,

I'm adding a new item "grapefruit_soda" that requires a water potion and other items for it to be crafted, however im having trouble when adding the water potion since it is not directly an "Item", when I go into the game and look for the recipe I just get a Uncraftable Potion, I tried creating a customized shapelessRecipeBuilder Class and directly get the water potion in the ModRecipeProvider class but i've unsuccessfull; 

My code for the ModRecipeBuilder classs and grapefruit_soda item.

Spoiler

ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, ModItems.GRAPEFRUIT_SODA.get(), 1) .requires(ModItems.PURPLE_HAZE_BUD.get(), 3) .unlockedBy(getHasName(ModItems.WEED_BUD.get()), has(ModItems.WEED_BUD.get())) .requires(Items.CHORUS_FRUIT, 2) .unlockedBy(getHasName(Items.CHORUS_FRUIT), has(Items.CHORUS_FRUIT)) .requires(Ingredient.of(PotionUtils.setPotion(new ItemStack(Items.POTION), Potions.WATER))) .save(pWriter);

 

How can I go about this, thanks in advance.

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.