From d23ed4386a27738d2bc239b41a3d52d176ad008b Mon Sep 17 00:00:00 2001 From: Lizbeth Rika Date: Sat, 15 Nov 2014 00:36:19 +0000 Subject: [PATCH] Fixed the game crashing if one tries to look up uses for the Tainted Blood Pendant in NEI. --- .../client/integration/nei/RecipeHandlerBrewery.java | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/main/java/vazkii/botania/client/integration/nei/RecipeHandlerBrewery.java b/src/main/java/vazkii/botania/client/integration/nei/RecipeHandlerBrewery.java index 488b7bf8e..b6174af27 100644 --- a/src/main/java/vazkii/botania/client/integration/nei/RecipeHandlerBrewery.java +++ b/src/main/java/vazkii/botania/client/integration/nei/RecipeHandlerBrewery.java @@ -112,10 +112,12 @@ public class RecipeHandlerBrewery extends TemplateRecipeHandler { @Override public void loadUsageRecipes(ItemStack ingredient) { - if (ingredient.getItem() instanceof IBrewContainer) - for (RecipeBrew recipe : BotaniaAPI.brewRecipes) - this.arecipes.add(new CachedBreweryRecipe(recipe, ingredient)); - else + if (ingredient.getItem() instanceof IBrewContainer) { + for(RecipeBrew recipe : BotaniaAPI.brewRecipes) { + if(recipe.getOutput(ingredient) != null) + this.arecipes.add(new CachedBreweryRecipe(recipe, ingredient)); + } + } else for (RecipeBrew recipe : BotaniaAPI.brewRecipes) { CachedBreweryRecipe crecipe = new CachedBreweryRecipe(recipe); if (crecipe.contains(crecipe.inputs, ingredient))