Whats wrong with my code for adding a new potion recipie?

Started by Muzaki on Thu, 07/29/2021 - 04:46

Topic category: Help with modding (Java Edition)

Last seen on 05:06, 30. Aug 2021
Joined Jul 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Whats wrong with my code for adding a new potion recipie?
Thu, 07/29/2021 - 04:46

I'm not sure what I'm doing wrong, any help is appreciated thanks.

heres the code:

 

package net.muzaki.minecraftenhanced;

import net.minecraftforge.fml.event.lifecycle.FMLCommonSetupEvent;
import net.minecraftforge.common.brewing.BrewingRecipeRegistry;

import net.minecraft.item.crafting.Ingredient;
import net.minecraft.item.Items;
import net.minecraft.item.ItemStack;
import net.minecraft.potion.Potions;
import net.minecraft.potion.Potion;
import net.minecraft.item.PotionItem;

import net.mcreator.potion.Energypotion;

@MinecraftEnhancedModElements.ModElement.Tag
public class EnergyregenpotionrecipieBrewingRecipe extends MinecraftEnhancedModElements.ModElement {
	public EnergyregenpotionrecipieBrewingRecipe(MinecraftEnhancedModElements instance) {
		super(instance, 42);
	}

	@Override
	public void init(FMLCommonSetupEvent event) {
		BrewingRecipeRegistry.addRecipe(Ingredient.fromStacks(new PotionItems(Potions.AWKWARD))), Ingredient.fromStacks(new ItemStack(Items.HONEYCOMB)),
				new ItemStack(Potions.ENERGYPOTION));
	}
}