Posted March 13, 20205 yr Okay, so this is kind of a follow-up to this post, so, I've now made a potion, and in the creative inventory, it appears. So do the Lingering and Splash variants. I do not want this. In the aforementioned post, diesieben07 mentioned using an IBrewingRecipe to do this. I have tried creating one for my potion, but I ended up deleting it in favour of BrewingRecipeRegistry.addRecipe(). However, my recipe doesn't work (I can't even insert my custom item that I want to use as an ingredient into a brewing stand), and I've no idea where in an IBrewingRecipe I''d disable potion variants. I'm 100% new to potions, how would I do this? All help appreciated! [Merged from a comment and edited to fit the present] Okay, now, I've made a new IBrewingRecipe class called FlyingPotionRecipe, here's the code: package ... import ... public class FlyingPotionRecipe implements IBrewingRecipe { private ItemStack output = PotionUtils.addPotionToItemStack(new ItemStack(Items.POTION), ModPotions.FLYING_POTION); @Override public boolean isInput(ItemStack input) { return input.getItem() == PotionUtils.addPotionToItemStack(input, Potions.WATER).getItem(); } @Override public boolean isIngredient(ItemStack ingredient) { return ingredient.getItem() == ModItems.GOLDEN_FEATHER; } @Override public ItemStack getOutput(ItemStack input, ItemStack ingredient) { return PotionUtils.addPotionToItemStack(output, ModPotions.FLYING_POTION); } } So, I've tested that now, and all looks good, but where in here would I set the splash and lingering potions on/off? TIA! Edited March 14, 20205 yr by BlockyPenguin Made title more descriptive Today (22/10/20) I reached 100 posts! I'm probably more excited than I should be for something so realistically minor...
March 13, 20205 yr Author Ignore this comment! ? sorry Edited March 13, 20205 yr by BlockyPenguin Merged with main post Today (22/10/20) I reached 100 posts! I'm probably more excited than I should be for something so realistically minor...
March 14, 20205 yr Author bump? Today (22/10/20) I reached 100 posts! I'm probably more excited than I should be for something so realistically minor...
March 16, 20205 yr Author I was trying to check if what was in the input slot is the correct input (a water bottle)... I'm guessing that's not what it does? I couldn't find much up-to-date documentation on brewing, sorry if this is an obvious solution. EDIT: So I've done some digging and I think what you saying is to check if the input is a splash water bottle, right? Please bear in mind, I'd like these potions to completely disappear from the game, even the creative inventory. If I'm right, making sure that the input is not a splash potion won't remove it from the registry. Edited March 16, 20205 yr by BlockyPenguin Today (22/10/20) I reached 100 posts! I'm probably more excited than I should be for something so realistically minor...
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.