// Path: src/main/java/brightspark/sparkshammers/hammerCrafting/HammerShapedOreRecipe.java
// public class HammerShapedOreRecipe extends IForgeRegistryEntry.Impl<HammerShapedOreRecipe>
// {
//     //Added in for future ease of change, but hard coded for now.
//     private static final int MAX_CRAFT_GRID_WIDTH = 5;
//     private static final int MAX_CRAFT_GRID_HEIGHT = 3;
// 
//     private ItemStack output = ItemStack.EMPTY;
//     private NonNullList<Ingredient> input = NonNullList.create();
//     public int width = 0;
//     public int height = 0;
// 
//     public HammerShapedOreRecipe(Block result, Object... recipe){ this(new ItemStack(result), recipe); }
//     public HammerShapedOreRecipe(Item result, Object... recipe){ this(new ItemStack(result), recipe); }
//     public HammerShapedOreRecipe(ItemStack result, Object... recipe)
//     {
//         output = result.copy();
//         CraftingHelper.ShapedPrimer primer = CraftingHelper.parseShaped(recipe);
//         width = primer.width;
//         height = primer.height;
//         input = primer.input;
//         setRegistryName(result.getItem().getRegistryName());
//     }
// 
//     public ItemStack getRecipeOutput(){ return output.copy(); }
// 
//     public NonNullList<ItemStack> getRemainingItems(InventoryCrafting inv)
//     {
//         return ForgeHooks.defaultRecipeGetRemainingItems(inv);
//     }
// 
//     /**
//      * Used to check if a recipe matches current crafting inventory
//      */
//     public boolean matches(InventoryCrafting inv)
//     {
//         for (int y = 0; y < MAX_CRAFT_GRID_HEIGHT; y++)
//         {
//             for (int x = 0; x < MAX_CRAFT_GRID_WIDTH; x++)
//             {
//                 Ingredient target = input.get(x + (y * MAX_CRAFT_GRID_WIDTH));
//                 ItemStack slot = inv.getStackInRowAndColumn(x, y);
// 
//                 if(!target.apply(slot))
//                     return false;
//             }
//         }
//         return true;
//     }
// 
//     @Override
//     public String toString()
//     {
//         StringBuilder str = new StringBuilder("Output: " + output.getUnlocalizedName() + ", Inputs: ");
//         for(Object o : input)
//         {
//             if(o instanceof ItemStack)
//                 str.append(((ItemStack)o).getUnlocalizedName());
//             else if(o instanceof Item)
//                 str.append(((Item)o).getUnlocalizedName());
//             else if(o instanceof Block)
//                 str.append(((Block)o).getUnlocalizedName());
//             else if(o instanceof String)
//                 str.append((String)o);
//             else if(o instanceof List)
//                 str.append("List of ").append(((List)o).size());
//             else
//                 str.append("<UNKNOWN>");
//             str.append(", ");
//         }
//         return str.toString().substring(0, str.length()-2);
//     }
// 
//     /**
//      * Gets the inputs
//      */
//     public NonNullList<Ingredient> getIngredients()
//     {
//         return input;
//     }
// }
// 
// Path: src/main/java/brightspark/sparkshammers/integration/jei/SparksHammersPlugin.java
// @JEIPlugin
// public class SparksHammersPlugin implements IModPlugin
// {
//     public static IJeiHelpers jeiHelper;
// 
//     @Override
//     public void registerCategories(@Nonnull IRecipeCategoryRegistration registry)
//     {
//         jeiHelper = registry.getJeiHelpers();
// 
//         registry.addRecipeCategories(new HammerCraftingRecipeCategory(jeiHelper.getGuiHelper()));
//     }
// 
//     @Override
//     public void register(@Nonnull IModRegistry registry)
//     {
//         registry.handleRecipes(HammerShapedOreRecipe.class, HammerCraftingRecipeWrapper.FACTORY, Reference.JEI.HAMMER_CRAFTING_UID);
//         registry.addRecipes(HammerCraftingManager.getValidRecipeList(), Reference.JEI.HAMMER_CRAFTING_UID);
//         registry.addRecipeClickArea(GuiHammerCraft.class, 111, 69, 26, 19, Reference.JEI.HAMMER_CRAFTING_UID);
//         registry.addRecipeCatalyst(new ItemStack(SHBlocks.blockHammerCraft), Reference.JEI.HAMMER_CRAFTING_UID);
// 
//         //Hide tools from JEI if you can't make them!
//         IIngredientBlacklist blacklist = jeiHelper.getIngredientBlacklist();
//         int count = 0;
//         for(ItemAOE tool : SHItems.AOE_TOOLS)
//         {
//             if(SparksHammers.shouldHideTool(tool))
//             {
//                 blacklist.addIngredientToBlacklist(new ItemStack(tool));
//                 count++;
//             }
//         }
//         if(count > 0)
//             LogHelper.info("Hidden " + count + " tools from JEI due to missing ingredients");
//     }
// }


import brightspark.sparkshammers.hammerCrafting.HammerShapedOreRecipe;
import brightspark.sparkshammers.integration.jei.SparksHammersPlugin;
import mezz.jei.api.ingredients.IIngredients;
import mezz.jei.api.recipe.IRecipeWrapper;
import mezz.jei.api.recipe.IRecipeWrapperFactory;
import net.minecraft.item.ItemStack;
import java.util.List;
package brightspark.sparkshammers.integration.jei.HammerCraftingTable;



public class HammerCraftingRecipeWrapper implements IRecipeWrapper
{
    public static final Factory FACTORY = new Factory();

    private List<List<ItemStack>> input;
    private ItemStack output;

// Path: src/main/java/brightspark/sparkshammers/hammerCrafting/HammerShapedOreRecipe.java
// public class HammerShapedOreRecipe extends IForgeRegistryEntry.Impl<HammerShapedOreRecipe>
// {
//     //Added in for future ease of change, but hard coded for now.
//     private static final int MAX_CRAFT_GRID_WIDTH = 5;
//     private static final int MAX_CRAFT_GRID_HEIGHT = 3;
// 
//     private ItemStack output = ItemStack.EMPTY;
//     private NonNullList<Ingredient> input = NonNullList.create();
//     public int width = 0;
//     public int height = 0;
// 
//     public HammerShapedOreRecipe(Block result, Object... recipe){ this(new ItemStack(result), recipe); }
//     public HammerShapedOreRecipe(Item result, Object... recipe){ this(new ItemStack(result), recipe); }
//     public HammerShapedOreRecipe(ItemStack result, Object... recipe)
//     {
//         output = result.copy();
//         CraftingHelper.ShapedPrimer primer = CraftingHelper.parseShaped(recipe);
//         width = primer.width;
//         height = primer.height;
//         input = primer.input;
//         setRegistryName(result.getItem().getRegistryName());
//     }
// 
//     public ItemStack getRecipeOutput(){ return output.copy(); }
// 
//     public NonNullList<ItemStack> getRemainingItems(InventoryCrafting inv)
//     {
//         return ForgeHooks.defaultRecipeGetRemainingItems(inv);
//     }
// 
//     /**
//      * Used to check if a recipe matches current crafting inventory
//      */
//     public boolean matches(InventoryCrafting inv)
//     {
//         for (int y = 0; y < MAX_CRAFT_GRID_HEIGHT; y++)
//         {
//             for (int x = 0; x < MAX_CRAFT_GRID_WIDTH; x++)
//             {
//                 Ingredient target = input.get(x + (y * MAX_CRAFT_GRID_WIDTH));
//                 ItemStack slot = inv.getStackInRowAndColumn(x, y);
// 
//                 if(!target.apply(slot))
//                     return false;
//             }
//         }
//         return true;
//     }
// 
//     @Override
//     public String toString()
//     {
//         StringBuilder str = new StringBuilder("Output: " + output.getUnlocalizedName() + ", Inputs: ");
//         for(Object o : input)
//         {
//             if(o instanceof ItemStack)
//                 str.append(((ItemStack)o).getUnlocalizedName());
//             else if(o instanceof Item)
//                 str.append(((Item)o).getUnlocalizedName());
//             else if(o instanceof Block)
//                 str.append(((Block)o).getUnlocalizedName());
//             else if(o instanceof String)
//                 str.append((String)o);
//             else if(o instanceof List)
//                 str.append("List of ").append(((List)o).size());
//             else
//                 str.append("<UNKNOWN>");
//             str.append(", ");
//         }
//         return str.toString().substring(0, str.length()-2);
//     }
// 
//     /**
//      * Gets the inputs
//      */
//     public NonNullList<Ingredient> getIngredients()
//     {
//         return input;
//     }
// }
// 
// Path: src/main/java/brightspark/sparkshammers/integration/jei/SparksHammersPlugin.java
// @JEIPlugin
// public class SparksHammersPlugin implements IModPlugin
// {
//     public static IJeiHelpers jeiHelper;
// 
//     @Override
//     public void registerCategories(@Nonnull IRecipeCategoryRegistration registry)
//     {
//         jeiHelper = registry.getJeiHelpers();
// 
//         registry.addRecipeCategories(new HammerCraftingRecipeCategory(jeiHelper.getGuiHelper()));
//     }
// 
//     @Override
//     public void register(@Nonnull IModRegistry registry)
//     {
//         registry.handleRecipes(HammerShapedOreRecipe.class, HammerCraftingRecipeWrapper.FACTORY, Reference.JEI.HAMMER_CRAFTING_UID);
//         registry.addRecipes(HammerCraftingManager.getValidRecipeList(), Reference.JEI.HAMMER_CRAFTING_UID);
//         registry.addRecipeClickArea(GuiHammerCraft.class, 111, 69, 26, 19, Reference.JEI.HAMMER_CRAFTING_UID);
//         registry.addRecipeCatalyst(new ItemStack(SHBlocks.blockHammerCraft), Reference.JEI.HAMMER_CRAFTING_UID);
// 
//         //Hide tools from JEI if you can't make them!
//         IIngredientBlacklist blacklist = jeiHelper.getIngredientBlacklist();
//         int count = 0;
//         for(ItemAOE tool : SHItems.AOE_TOOLS)
//         {
//             if(SparksHammers.shouldHideTool(tool))
//             {
//                 blacklist.addIngredientToBlacklist(new ItemStack(tool));
//                 count++;
//             }
//         }
//         if(count > 0)
//             LogHelper.info("Hidden " + count + " tools from JEI due to missing ingredients");
//     }
// }


// Path: src/main/java/brightspark/sparkshammers/integration/jei/HammerCraftingTable/HammerCraftingRecipeWrapper.java
import brightspark.sparkshammers.hammerCrafting.HammerShapedOreRecipe;
import brightspark.sparkshammers.integration.jei.SparksHammersPlugin;
import mezz.jei.api.ingredients.IIngredients;
import mezz.jei.api.recipe.IRecipeWrapper;
import mezz.jei.api.recipe.IRecipeWrapperFactory;
import net.minecraft.item.ItemStack;
import java.util.List;

package brightspark.sparkshammers.integration.jei.HammerCraftingTable;



public class HammerCraftingRecipeWrapper implements IRecipeWrapper
{
    public static final Factory FACTORY = new Factory();

    private List<List<ItemStack>> input;
    private ItemStack output;

    public HammerCraftingRecipeWrapper(HammerShapedOreRecipe recipe)