diff --git a/src/main/java/mekanism/common/integration/crafttweaker/helpers/IngredientHelper.java b/src/main/java/mekanism/common/integration/crafttweaker/helpers/IngredientHelper.java index 625b51412..efc91f5e1 100644 --- a/src/main/java/mekanism/common/integration/crafttweaker/helpers/IngredientHelper.java +++ b/src/main/java/mekanism/common/integration/crafttweaker/helpers/IngredientHelper.java @@ -73,9 +73,9 @@ public static boolean matches(IIngredient input, IIngredient toMatch) { if (input instanceof IGasStack) { return GasHelper.matches(toMatch, (IGasStack) input); } else if (input instanceof IItemStack) { - return ingredientMatchesStack(toMatch, (IItemStack) input); + return toMatch != null && toMatch.matches((IItemStack) input); } else if (input instanceof ILiquidStack) { - return ingredientMatchesLiquid(toMatch, (ILiquidStack) input); + return toMatch != null && toMatch.matches((ILiquidStack) input); } //TODO: Support other types of things like ore dict return false; @@ -167,31 +167,4 @@ public static ItemStack toStack(IItemStack stack) { public static FluidStack toFluid(ILiquidStack fluid) { return fluid == null ? null : FluidRegistry.getFluidStack(fluid.getName(), fluid.getAmount()); } - - public static boolean ingredientMatchesStack(IIngredient ingredient, IItemStack itemStack) { - return ingredient != null && ingredient.matches(itemStack); - } - - public static boolean ingredientMatchesLiquid(IIngredient ingredient, ILiquidStack liquidStack) { - return ingredient != null && ingredient.matches(liquidStack); - /*if(ingredient == null) { - return false; - } - - // Do we have a wildcard (<*>) ? - if(ingredient.matches(liquidStack)) { - return true; - } - - // Does ingredient reference liquids? - if(ingredient.getLiquids() != null) { - for (ILiquidStack liquid : ingredient.getLiquids()) { - if(InputHelper.toFluid(liquid).isFluidEqual(InputHelper.toFluid(liquidStack))) { - return true; - } - } - } - - return false;*/ - } } \ No newline at end of file