Skip to content

Commit

Permalink
Add back Recipe Removing. Closes #160
Browse files Browse the repository at this point in the history
  • Loading branch information
alexbegt committed Jan 10, 2018
1 parent 9ba1e03 commit 669beff
Showing 1 changed file with 5 additions and 3 deletions.
Expand Up @@ -13,6 +13,8 @@
import net.minecraft.item.crafting.ShapelessRecipes;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.fml.common.registry.ForgeRegistries;
import net.minecraftforge.registries.GameData;
import net.minecraftforge.registries.RegistryManager;

public class RecipeRemover
{
Expand All @@ -34,7 +36,7 @@ public static void removeAnyRecipe(ItemStack resultItem)

if (ItemStack.areItemStacksEqual(resultItem, recipeResult))
{
//RegistryManager.ACTIVE.getRegistry(GameData.RECIPES).remove(recipe.getKey());
RegistryManager.ACTIVE.getRegistry(GameData.RECIPES).remove(recipe.getKey());
}
}
}
Expand All @@ -54,7 +56,7 @@ public static void removeShapedRecipe(ItemStack resultItem)

if (ItemStack.areItemStacksEqual(resultItem, recipeResult))
{
//RegistryManager.ACTIVE.getRegistry(GameData.RECIPES).remove(recipe.getKey());
RegistryManager.ACTIVE.getRegistry(GameData.RECIPES).remove(recipe.getKey());
}
}
}
Expand All @@ -75,7 +77,7 @@ public static void removeShapelessRecipe(ItemStack resultItem)

if (ItemStack.areItemStacksEqual(resultItem, recipeResult))
{
//RegistryManager.ACTIVE.getRegistry(GameData.RECIPES).remove(recipe.getKey());
RegistryManager.ACTIVE.getRegistry(GameData.RECIPES).remove(recipe.getKey());
}
}
}
Expand Down

0 comments on commit 669beff

Please sign in to comment.