本文整理汇总了Java中net.minecraftforge.common.brewing.BrewingRecipeRegistry类的典型用法代码示例。如果您正苦于以下问题:Java BrewingRecipeRegistry类的具体用法?Java BrewingRecipeRegistry怎么用?Java BrewingRecipeRegistry使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
BrewingRecipeRegistry类属于net.minecraftforge.common.brewing包,在下文中一共展示了BrewingRecipeRegistry类的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: registerUpgrades
import net.minecraftforge.common.brewing.BrewingRecipeRegistry; //导入依赖的package包/类
private static void registerUpgrades(PotionType normal, PotionType extended, PotionType strong) {
BrewingRecipeRegistry.addRecipe(createBrewingRecipe(normal, new ItemStack(Items.REDSTONE), extended));
BrewingRecipeRegistry.addRecipe(createBrewingRecipe(strong, new ItemStack(Items.REDSTONE), extended));
BrewingRecipeRegistry.addRecipe(createBrewingRecipe(normal, new ItemStack(Items.GLOWSTONE_DUST), strong));
BrewingRecipeRegistry.addRecipe(createBrewingRecipe(extended, new ItemStack(Items.GLOWSTONE_DUST), strong));
BrewingRecipeRegistry.addRecipe(createSplashBrewingRecipe(normal, new ItemStack(Items.REDSTONE), extended));
BrewingRecipeRegistry.addRecipe(createSplashBrewingRecipe(strong, new ItemStack(Items.REDSTONE), extended));
BrewingRecipeRegistry.addRecipe(createSplashBrewingRecipe(normal, new ItemStack(Items.GLOWSTONE_DUST), strong));
BrewingRecipeRegistry.addRecipe(createSplashBrewingRecipe(extended, new ItemStack(Items.GLOWSTONE_DUST), strong));
BrewingRecipeRegistry.addRecipe(createLingeringBrewingRecipe(normal, new ItemStack(Items.REDSTONE), extended));
BrewingRecipeRegistry.addRecipe(createLingeringBrewingRecipe(strong, new ItemStack(Items.REDSTONE), extended));
BrewingRecipeRegistry.addRecipe(createLingeringBrewingRecipe(normal, new ItemStack(Items.GLOWSTONE_DUST), strong));
BrewingRecipeRegistry.addRecipe(createLingeringBrewingRecipe(extended, new ItemStack(Items.GLOWSTONE_DUST), strong));
BrewingRecipeRegistry.addRecipe(new BrewingRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.POTIONITEM), normal), new ItemStack(Items.GUNPOWDER), (PotionUtils.addPotionToItemStack(new ItemStack(Items.SPLASH_POTION), normal))));
BrewingRecipeRegistry.addRecipe(new BrewingRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.SPLASH_POTION), normal), new ItemStack(Items.DRAGON_BREATH), (PotionUtils.addPotionToItemStack(new ItemStack(Items.LINGERING_POTION), normal))));
}
示例2: addBrewingRecipe
import net.minecraftforge.common.brewing.BrewingRecipeRegistry; //导入依赖的package包/类
/**
* Currently not used but it does work.
*
* has built in unit test
*
* @param input
* @param ingredient
* @param output
* @return
*/
public static BrewingRecipe addBrewingRecipe(ItemStack input, ItemStack ingredient, ItemStack output) {
if (input.isEmpty() || input.getItem() == null) {
return null;
}
BrewingRecipe recipe = new BrewingRecipe(
input,
ingredient,
output);
BrewingRecipeRegistry.addRecipe(recipe);
if (ModCyclic.logger.runUnitTests()) {//OMG UNIT TESTING WAAT
ItemStack output0 = BrewingRecipeRegistry.getOutput(input, ingredient);
if (output0.getItem() == output.getItem())
ModCyclic.logger.logTestResult("Brewing Recipe succefully registered and working: " + output.getUnlocalizedName());
else {
ModCyclic.logger.logTestResult("Brewing Recipe FAILED to register" + output.getUnlocalizedName());
}
}
return recipe;
}
示例3: performWork
import net.minecraftforge.common.brewing.BrewingRecipeRegistry; //导入依赖的package包/类
@Override
public float performWork() {
if (WorkUtils.isDisabled(this.getBlockType())) return 0;
if (action > 5) action = 0;
if (action != 0 && outputPotions.getStackInSlot(0).isEmpty() && outputPotions.getStackInSlot(1).isEmpty() && outputPotions.getStackInSlot(2).isEmpty()) {
action = 0;
partialSync(NBT_ACTION, true);
return 1;
}
if (action == 0 && inputGlassBottles.getStackInSlot(0).getCount() >= 3 && ItemHandlerHelper.insertItem(outputPotions, new ItemStack(Items.POTIONITEM, 3), true).isEmpty() && fluidTank.getFluidAmount() >= 3000) { //DUMMY STACK
ItemStack bottles = new ItemStack(Items.POTIONITEM, 3);
NBTTagCompound c = new NBTTagCompound();
c.setString("Potion", "minecraft:water");
bottles.setTagCompound(c);
ItemHandlerHelper.insertItem(outputPotions, bottles, false);
fluidTank.drain(3000, true);
inputGlassBottles.getStackInSlot(0).setCount(inputGlassBottles.getStackInSlot(0).getCount() - 3);
action = 1;
partialSync(NBT_ACTION, true);
return 1;
} else if (action > 0) {
ItemStack ingredient = inputIngredients.getStackInSlot(action - 1);
if (!ingredient.isEmpty()) {
NonNullList<ItemStack> potions = NonNullList.create();
potions.add(outputPotions.getStackInSlot(0));
potions.add(outputPotions.getStackInSlot(1));
potions.add(outputPotions.getStackInSlot(2));
if (BrewingRecipeRegistry.hasOutput(potions.get(0), ingredient)) {
BrewingRecipeRegistry.brewPotions(potions, ingredient, new int[]{0, 1, 2});
for (int i = 0; i < 3; ++i) outputPotions.setStackInSlot(i, potions.get(i));
++action;
ingredient.setCount(ingredient.getCount() - 1);
if (action > 5) action = 0;
partialSync(NBT_ACTION, true);
return 1;
}
}
}
return 0;
}
示例4: register
import net.minecraftforge.common.brewing.BrewingRecipeRegistry; //导入依赖的package包/类
public static void register() {
GameRegistry.register(HYPOTHERMIA, new ResourceLocation("seasonsapi", "hyporthermia"));
GameRegistry.register(BURNT, new ResourceLocation("seasonsapi", "burnt"));
GameRegistry.register(hypothermia, new ResourceLocation("seasonsapi", "hypothermia"));
GameRegistry.register(hypothermia_long, new ResourceLocation("seasonsapi", "long_hypothermia"));
GameRegistry.register(hypothermia_strong, new ResourceLocation("seasonsapi", "strong_hypothermia"));
GameRegistry.register(burnt, new ResourceLocation("seasonsapi", "burnt"));
GameRegistry.register(burnt_long, new ResourceLocation("seasonsapi", "long_burnt"));
GameRegistry.register(burnt_strong, new ResourceLocation("seasonsapi", "strong_burnt"));
BrewingRecipeRegistry.addRecipe(createBrewingRecipe(PotionTypes.AWKWARD, new ItemStack(Items.SNOWBALL), hypothermia));
BrewingRecipeRegistry.addRecipe(createBrewingRecipe(PotionTypes.AWKWARD, new ItemStack(Items.FIRE_CHARGE), burnt));
registerUpgrades(hypothermia, hypothermia_long, hypothermia_strong);
registerUpgrades(burnt, burnt_long, burnt_strong);
}
示例5: init
import net.minecraftforge.common.brewing.BrewingRecipeRegistry; //导入依赖的package包/类
public static void init () {
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.EmptyBottle), new ItemStack(ModItems.HpOrb), new ItemStack(ModItems.Potion));
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.EmptyBottle), new ItemStack(ModItems.MagicOrb), new ItemStack(ModItems.Ether));
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.Ether), new ItemStack(ModItems.MagicOrb), new ItemStack(ModItems.MegaEther));
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.EmptyBottle), new ItemStack(ModItems.Ether), new ItemStack(ModItems.MegaEther));
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.Potion), new ItemStack(ModItems.MagicOrb), new ItemStack(ModItems.Elixir));
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.Ether), new ItemStack(ModItems.HpOrb), new ItemStack(ModItems.Elixir));
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.MegaEther), new ItemStack(ModItems.HiPotion), new ItemStack(ModItems.Megalixir));
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.EmptyBottle), new ItemStack(ModItems.Potion), new ItemStack(ModItems.HiPotion));
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.Potion), new ItemStack(ModItems.HpOrb), new ItemStack(ModItems.HiPotion));
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.EmptyBottle), new ItemStack(ModItems.HiPotion), new ItemStack(ModItems.MegaPotion));
BrewingRecipeRegistry.addRecipe(new ItemStack(ModItems.HiPotion), new ItemStack(ModItems.HpOrb), new ItemStack(ModItems.MegaPotion));
}
示例6: cancelCertainPotionBrewing
import net.minecraftforge.common.brewing.BrewingRecipeRegistry; //导入依赖的package包/类
@SubscribeEvent
public void cancelCertainPotionBrewing(PotionBrewEvent.Pre evt) {
ItemStack modifier = evt.getItem(3);
for (int i = 0; i < evt.getLength(); i++) {
ItemStack stack = evt.getItem(i);
if (!stack.isEmpty()) {
ItemStack output = BrewingRecipeRegistry.getOutput(stack, modifier);
if (output.getItem() instanceof ItemPotion) {
if (!ConfigHandler.allowBrewingPotionSplash && output.getItem() instanceof ItemSplashPotion) {
evt.setCanceled(true);
return;
}
if (!ConfigHandler.allowBrewingPotionLingering && output.getItem() instanceof ItemLingeringPotion) {
evt.setCanceled(true);
return;
}
List<PotionEffect> potionEffects = PotionUtils.getEffectsFromStack(output);
for (PotionEffect effect : potionEffects) {
if (effect.getAmplifier() > ConfigHandler.brewingPotionMaxLevel) {
evt.setCanceled(true);
return;
}
if (!ConfigHandler.allowBrewingPotionRegen && effect.getPotion() == MobEffects.REGENERATION) {
evt.setCanceled(true);
return;
}
}
}
}
}
}
示例7: initPotions
import net.minecraftforge.common.brewing.BrewingRecipeRegistry; //导入依赖的package包/类
public static void initPotions(){
ForgeRegistries.POTION_TYPES.register(COKE_COLA);
ForgeRegistries.POTION_TYPES.register(COKE_COLA_LONG);
ForgeRegistries.POTION_TYPES.register(COKE_COLA_STRONG);
Coke_Cola_Bottle=PotionUtils.addPotionToItemStack(new ItemStack(Items.POTIONITEM), COKE_COLA);
Coke_Cola_Bottle_Long=PotionUtils.addPotionToItemStack(new ItemStack(Items.POTIONITEM), COKE_COLA_LONG);
Coke_Cola_Bottle_Strong=PotionUtils.addPotionToItemStack(new ItemStack(Items.POTIONITEM), COKE_COLA_STRONG);
Coke_Cola_Splash_Bottle=PotionUtils.addPotionToItemStack(new ItemStack(Items.SPLASH_POTION), COKE_COLA);
Coke_Cola_Splash_Bottle_Long=PotionUtils.addPotionToItemStack(new ItemStack(Items.SPLASH_POTION), COKE_COLA_LONG);
Coke_Cola_Splash_Bottle_Strong=PotionUtils.addPotionToItemStack(new ItemStack(Items.SPLASH_POTION), COKE_COLA_STRONG);
Coke_Cola_Lingering_Bottle=PotionUtils.addPotionToItemStack(new ItemStack(Items.LINGERING_POTION), COKE_COLA);
Coke_Cola_Lingeting_Bottle_Long=PotionUtils.addPotionToItemStack(new ItemStack(Items.LINGERING_POTION), COKE_COLA_LONG);
Coke_Cola_Lingering_Bottle_Strong=PotionUtils.addPotionToItemStack(new ItemStack(Items.LINGERING_POTION), COKE_COLA_STRONG);
Coke_Cola_Bottle.getTagCompound().setInteger("CustomPotionColor", 4738376);
Coke_Cola_Bottle_Long.getTagCompound().setInteger("CustomPotionColor", 4738376);
Coke_Cola_Bottle_Strong.getTagCompound().setInteger("CustomPotionColor", 4738376);
Coke_Cola_Splash_Bottle.getTagCompound().setInteger("CustomPotionColor", 4738376);
Coke_Cola_Splash_Bottle_Long.getTagCompound().setInteger("CustomPotionColor", 4738376);
Coke_Cola_Splash_Bottle_Strong.getTagCompound().setInteger("CustomPotionColor", 4738376);
Coke_Cola_Lingering_Bottle.getTagCompound().setInteger("CustomPotionColor", 4738376);
Coke_Cola_Lingeting_Bottle_Long.getTagCompound().setInteger("CustomPotionColor", 4738376);
Coke_Cola_Lingering_Bottle_Strong.getTagCompound().setInteger("CustomPotionColor", 4738376);
//speed to coke
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.POTIONITEM), PotionTypes.SWIFTNESS), "fuelCoke", Coke_Cola_Bottle));
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.POTIONITEM), PotionTypes.LONG_SWIFTNESS), "fuelCoke", Coke_Cola_Bottle_Long));
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.POTIONITEM), PotionTypes.STRONG_SWIFTNESS), "fuelCoke", Coke_Cola_Bottle_Strong));
//splash
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.SPLASH_POTION), PotionTypes.SWIFTNESS), "fuelCoke", Coke_Cola_Splash_Bottle));
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.SPLASH_POTION), PotionTypes.LONG_SWIFTNESS), "fuelCoke", Coke_Cola_Splash_Bottle_Long));
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.SPLASH_POTION), PotionTypes.STRONG_SWIFTNESS), "fuelCoke", Coke_Cola_Splash_Bottle_Strong));
//lingering
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.LINGERING_POTION), PotionTypes.SWIFTNESS), "fuelCoke", Coke_Cola_Lingering_Bottle));
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.LINGERING_POTION), PotionTypes.LONG_SWIFTNESS), "fuelCoke", Coke_Cola_Lingeting_Bottle_Long));
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(PotionUtils.addPotionToItemStack(new ItemStack(Items.LINGERING_POTION), PotionTypes.STRONG_SWIFTNESS), "fuelCoke", Coke_Cola_Lingering_Bottle_Strong));
//boosts
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(Coke_Cola_Bottle, "dustRedstone", Coke_Cola_Bottle_Long));
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(Coke_Cola_Bottle, "dustGlowstone", Coke_Cola_Bottle_Strong));
//splash
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(Coke_Cola_Splash_Bottle, "dustRedstone", Coke_Cola_Splash_Bottle_Long));
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(Coke_Cola_Splash_Bottle, "dustGlowstone", Coke_Cola_Splash_Bottle_Strong));
//lingering
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(Coke_Cola_Lingering_Bottle, "dustRedstone", Coke_Cola_Lingeting_Bottle_Long));
BrewingRecipeRegistry.addRecipe(new BrewingNBTRecipe(Coke_Cola_Lingering_Bottle, "dustGlowstone", Coke_Cola_Lingering_Bottle_Strong));
}
示例8: init
import net.minecraftforge.common.brewing.BrewingRecipeRegistry; //导入依赖的package包/类
public static void init() {
initEdibleMetals();
UCBaubles.initRecipes();
ItemStack precisionAxe = new ItemStack(UCItems.precisionAxe);
precisionAxe.addEnchantment(Enchantment.getEnchantmentByID(33), 1);
ItemStack precisionShovel = new ItemStack(UCItems.precisionShovel);
precisionShovel.addEnchantment(Enchantment.getEnchantmentByID(33), 1);
ItemStack precisionPick = new ItemStack(UCItems.precisionPick);
precisionPick.addEnchantment(Enchantment.getEnchantmentByID(33), 1);
GameRegistry.addRecipe(precisionAxe, "GG ", "GS ", " S ", 'G', UCItems.generic.createStack(EnumItems.PREGEM), 'S', Items.STICK);
GameRegistry.addRecipe(precisionPick, "GGG", " S ", " S ", 'G', UCItems.generic.createStack(EnumItems.PREGEM), 'S', Items.STICK);
GameRegistry.addRecipe(precisionShovel, " G ", " S ", " S ", 'G', UCItems.generic.createStack(EnumItems.PREGEM), 'S', Items.STICK);
GameRegistry.addShapelessRecipe(new ItemStack(UCItems.dietpills), UCItems.generic.createStack(EnumItems.ABSTRACT), UCItems.generic.createStack(EnumItems.ABSTRACT), Items.GLASS_BOTTLE);
GameRegistry.addShapelessRecipe(new ItemStack(UCItems.seedsAbstract), UCItems.generic.createStack(EnumItems.ABSTRACT));
GameRegistry.addRecipe(UCItems.generic.createStack(EnumItems.GUIDE), " N ", "WBM", " P ", 'N', new ItemStack(UCItems.seedsNormal), 'W', Items.WHEAT_SEEDS, 'M', Items.MELON_SEEDS, 'P', Items.PUMPKIN_SEEDS, 'B', Items.BOOK);
GameRegistry.addRecipe(UCItems.generic.createStack(EnumItems.EGGUPGRADE), "IEI", "EME", "IEI", 'I', Items.IRON_INGOT, 'E', Items.EGG, 'M', UCItems.generic.createStack(EnumItems.MILLENNIUMEYE));
GameRegistry.addRecipe(UCItems.generic.createStack(EnumItems.EASYBADGE), "GEG", "EQE", "GEG", 'G', Items.GOLD_INGOT, 'Q', Blocks.QUARTZ_BLOCK, 'E', UCItems.generic.createStack(EnumItems.MILLENNIUMEYE));
GameRegistry.addRecipe(new ItemStack(UCBlocks.lavalily), " C ", "CLC", " C ", 'C', UCItems.generic.createStack(EnumItems.CINDERLEAF), 'L', Blocks.WATERLILY);
GameRegistry.addRecipe(UCItems.generic.createStack(EnumItems.UPGRADE), " F ", "FBF", " F ", 'F', UCItems.generic.createStack(EnumItems.INVISIFEATHER), 'B', UCItems.generic.createStack(EnumItems.DISCOUNT));
GameRegistry.addRecipe(new ItemStack(UCItems.largeplum), "PPP", "PPP", "PPP", 'P', UCItems.generic.createStack(EnumItems.PLUM));
GameRegistry.addRecipe(new ItemStack(UCItems.goldenbread), "RRR", 'R', UCItems.generic.createStack(EnumItems.GOLDENRODS));
GameRegistry.addRecipe(UCItems.generic.createStack(EnumItems.WEEPINGEYE), "TTT", "TET", "TTT", 'T', UCItems.generic.createStack(EnumItems.WEEPINGTEAR), 'E', Items.ENDER_EYE);
GameRegistry.addRecipe(new ItemStack(UCItems.poncho), "P P", "PPP", "PPP", 'P', UCItems.generic.createStack(EnumItems.INVISIFEATHER));
GameRegistry.addRecipe(UCItems.generic.createStack(EnumItems.INVISIFEATHER), "TTT", "TFT", "TTT", 'T', UCItems.generic.createStack(EnumItems.INVISITWINE), 'F', Items.FEATHER);
GameRegistry.addRecipe(new ItemStack(UCItems.glasses3D), "I I", "I I", "BWR", 'I', Items.IRON_INGOT, 'R', new ItemStack(Blocks.STAINED_GLASS_PANE, 1, EnumDyeColor.RED.getMetadata()), 'W', new ItemStack(Blocks.WOOL, 1, EnumDyeColor.WHITE.getMetadata()), 'B', new ItemStack(Blocks.STAINED_GLASS_PANE, 1, EnumDyeColor.BLUE.getMetadata()));
GameRegistry.addRecipe(new ItemStack(UCItems.pixelglasses), "PPP", "PGP", "PPP", 'G', UCItems.glasses3D, 'P', UCItems.generic.createStack(EnumItems.PIXELS));
GameRegistry.addRecipe(UCItems.generic.createStack(EnumItems.TIMEMEAL, 3), " B ", "BCB", " B ", 'B', new ItemStack(Items.DYE, 1, EnumDyeColor.WHITE.getDyeDamage()), 'C', Items.CLOCK);
GameRegistry.addRecipe(new ItemStack(UCItems.endersnooker), "EPE", "PSP", "EPE", 'E', UCItems.generic.createStack(EnumItems.LILYTWINE), 'S', Items.STICK, 'P', Items.ENDER_PEARL);
GameRegistry.addRecipe(new ItemStack(Items.ENDER_PEARL), "EEE", "ESE", "EEE", 'E', UCItems.generic.createStack(EnumItems.LILYTWINE), 'S', Items.SNOWBALL);
GameRegistry.addRecipe(UCItems.generic.createStack(EnumItems.PREGEM), " N ", "NDN", " N ", 'N', UCItems.generic.createStack(EnumItems.PRENUGGET), 'D', Items.DIAMOND);
GameRegistry.addRecipe(new ItemStack(UCBlocks.hourglass), "DGD", "PDP", "DGD", 'G', Blocks.GOLD_BLOCK, 'P', Blocks.GLASS_PANE, 'D', UCItems.generic.createStack(EnumItems.TIMEDUST));
GameRegistry.addRecipe(new ItemStack(UCBlocks.totemhead), "LLL", "LML", " S ", 'L', Blocks.LAPIS_BLOCK, 'M', UCItems.generic.createStack(EnumItems.MILLENNIUMEYE), 'S', Items.STICK);
GameRegistry.addRecipe(UCItems.generic.createStack(EnumItems.EULA), " L ", "LBL", " L ", 'L', UCItems.generic.createStack(EnumItems.LEGALSTUFF), 'B', Items.BOOK);
GameRegistry.addRecipe(new ItemStack(UCItems.seedsArtisia), " S ", "SCS", " S ", 'S', UCItems.seedsNormal, 'C', Blocks.CRAFTING_TABLE);
GameRegistry.addRecipe(new DiscountBookRecipe());
BrewingRecipeRegistry.addRecipe(BrewingRecipeRegistry.getOutput(new ItemStack(Items.POTIONITEM), new ItemStack(Items.NETHER_WART)), UCItems.generic.createStack(EnumItems.TIMEDUST), new ItemStack(UCItems.potionreverse));
BrewingRecipeRegistry.addRecipe(new ItemStack(UCItems.potionreverse), new ItemStack(Items.GUNPOWDER), UCItems.generic.createStack(EnumItems.POTIONSPLASH));
for (EnumDyeColor dye : EnumDyeColor.values()) {
addSeedRecipe(getDyeCraftingResult(dye.getDyeDamage()), new ItemStack(Items.DYE, 1, dye.getMetadata()), UCItems.generic.createStack(EnumItems.ESSENCE), UCItems.generic.createStack(EnumItems.ESSENCE));
}
addSeedRecipe(new ItemStack(UCItems.seedsCinderbella), new ItemStack(Items.SUGAR), new ItemStack(Items.WHEAT_SEEDS), new ItemStack(UCItems.seedsNormal));
addSeedRecipe(new ItemStack(UCItems.seedsCollis), new ItemStack(Items.SUGAR), new ItemStack(UCItems.seedsNormal), new ItemStack(UCItems.seedsCinderbella));
addSeedRecipe(new ItemStack(UCItems.seedsDirigible), new ItemStack(Items.SUGAR), new ItemStack(Items.PUMPKIN_SEEDS), new ItemStack(UCItems.seedsCollis));
addSeedRecipe(new ItemStack(UCItems.seedsEnderlily), new ItemStack(Items.ENDER_EYE), new ItemStack(Items.ENDER_PEARL), new ItemStack(UCItems.seedsDirigible));
addSeedRecipe(new ItemStack(UCItems.seedsInvisibilia), new ItemStack(Items.SUGAR), new ItemStack(Blocks.GLASS), new ItemStack(UCItems.seedsCinderbella));
addSeedRecipe(new ItemStack(UCItems.seedsKnowledge), new ItemStack(Items.SUGAR), new ItemStack(Items.ENCHANTED_BOOK), new ItemStack(UCItems.seedsInvisibilia));
addSeedRecipe(new ItemStack(UCItems.seedsMaryjane), new ItemStack(Items.BLAZE_ROD), new ItemStack(Items.BLAZE_POWDER), new ItemStack(UCItems.seedsCollis));
addSeedRecipe(new ItemStack(UCItems.seedsMerlinia), new ItemStack(Items.PUMPKIN_SEEDS), UCItems.generic.createStack(EnumItems.TIMEMEAL), new ItemStack(UCItems.seedsEnderlily));
addSeedRecipe(new ItemStack(UCItems.seedsMillennium), new ItemStack(Items.CLOCK), new ItemStack(Items.PUMPKIN_SEEDS), new ItemStack(UCItems.seedsMerlinia));
addSeedRecipe(new ItemStack(UCItems.seedsMusica), new ItemStack(Blocks.JUKEBOX), new ItemStack(UCItems.seedsNormal), new ItemStack(UCItems.seedsMaryjane));
addSeedRecipe(new ItemStack(UCItems.seedsPrecision), new ItemStack(Items.GOLD_NUGGET), new ItemStack(UCItems.seedsCollis), new ItemStack(UCItems.seedsInvisibilia));
addSeedRecipe(new ItemStack(UCItems.seedsWeepingbells), new ItemStack(Items.GHAST_TEAR), new ItemStack(Items.MELON_SEEDS), new ItemStack(UCItems.seedsEnderlily));
addSeedRecipe(new ItemStack(UCItems.seedsAbstract), new ItemStack(Items.REEDS), new ItemStack(Blocks.STAINED_HARDENED_CLAY), new ItemStack(Blocks.WOOL));
addSeedRecipe(new ItemStack(UCItems.seedsCobblonia), new ItemStack(Blocks.COBBLESTONE), new ItemStack(Blocks.STONEBRICK), new ItemStack(UCItems.seedsNormal));
addSeedRecipe(new ItemStack(UCItems.seedsDyeius), new ItemStack(Blocks.WOOL), new ItemStack(Items.DYE), new ItemStack(UCItems.seedsAbstract));
addSeedRecipe(new ItemStack(UCItems.seedsEula), new ItemStack(Items.PAPER), new ItemStack(Items.BOOK), new ItemStack(UCItems.seedsCobblonia));
addSeedRecipe(new ItemStack(UCItems.seedsFeroxia), new ItemStack(Items.CLAY_BALL), new ItemStack(UCItems.seedsKnowledge), new ItemStack(UCItems.seedsWeepingbells));
addSeedRecipe(new ItemStack(UCItems.seedsWafflonia), new ItemStack(Items.WHEAT_SEEDS), new ItemStack(Items.BREAD), new ItemStack(Items.SUGAR));
addSeedRecipe(new ItemStack(UCItems.seedsPixelsius), new ItemStack(UCItems.seedsWafflonia), new ItemStack(Items.DYE, 1, EnumDyeColor.BLACK.getDyeDamage()), new ItemStack(Items.PAINTING));
addSeedRecipe(new ItemStack(UCItems.seedsDevilsnare), new ItemStack(UCItems.seedsPixelsius), new ItemStack(Items.STICK), new ItemStack(Blocks.LOG));
addSeedRecipe(new ItemStack(UCItems.seedsMalleatoris), new ItemStack(UCItems.seedsPrecision), new ItemStack(Blocks.ANVIL), new ItemStack(Items.IRON_INGOT));
addSeedRecipe(new ItemStack(UCItems.seedsPetramia), new ItemStack(UCItems.seedsCobblonia), new ItemStack(Blocks.OBSIDIAN), new ItemStack(Blocks.COBBLESTONE));
}
示例9: apply
import net.minecraftforge.common.brewing.BrewingRecipeRegistry; //导入依赖的package包/类
@Override
public void apply() {
LogHelper.info("Adding brewing recipe for " + output.toString());
BrewingRecipeRegistry.addRecipe(recipe);
}
示例10: addPotionRecipe
import net.minecraftforge.common.brewing.BrewingRecipeRegistry; //导入依赖的package包/类
/**
* Adds a potion recipe
* @param input The ItemStack input, this goes in the potion slot. Must have a max stack size of 1.
* @param inputPot The PotionType that will go on the input ItemStack.
* @param reagent The ItemStack reagent, this goes in the top slot.
* @param output The ItemStack output, this is what the input transforms into after brewing.
* @param ontputPot The PotionType that will go on the output ItemStack.
*/
public static void addPotionRecipe(ItemStack input, PotionType inputPot, ItemStack reagent, ItemStack output,
PotionType ontputPot)
{
BrewingRecipeRegistry.addRecipe(PotionUtils.addPotionToItemStack(input, inputPot), reagent,
PotionUtils.addPotionToItemStack(output, ontputPot));
}