package com.yolp900.itsjustacharm.common.integration.jei;
import com.yolp900.itsjustacharm.client.guis.GuiConstructionTable;
import com.yolp900.itsjustacharm.common.blocks.ModBlocks;
import com.yolp900.itsjustacharm.common.integration.jei.constructionTable.RecipeCategoryConstructionTable;
import com.yolp900.itsjustacharm.common.integration.jei.constructionTable.RecipeHandlerConstructionTable;
import com.yolp900.itsjustacharm.common.integration.jei.constructionTable.RecipeMakerConstructionTable;
import com.yolp900.itsjustacharm.common.inventory.ContainerConstructionTable;
import com.yolp900.itsjustacharm.reference.LibModIntegrations;
import mezz.jei.api.*;
import mezz.jei.api.recipe.VanillaRecipeCategoryUid;
import mezz.jei.api.recipe.transfer.IRecipeTransferRegistry;
import net.minecraft.item.ItemStack;
import javax.annotation.Nonnull;
@JEIPlugin
public class IJCPlugin extends BlankModPlugin {
public static IJeiHelpers jeiHelpers;
@Override
public void register(@Nonnull IModRegistry registry) {
jeiHelpers = registry.getJeiHelpers();
IRecipeTransferRegistry recipeTransferRegistry = registry.getRecipeTransferRegistry();
registry.addRecipeCategories(new RecipeCategoryConstructionTable());
registry.addRecipeHandlers(new RecipeHandlerConstructionTable());
registry.addRecipes(RecipeMakerConstructionTable.getRecipes());
registry.addRecipeClickArea(GuiConstructionTable.class, 161, 71, 22, 15, LibModIntegrations.JEI.Recipes.ConstructionTable.getUid());
recipeTransferRegistry.addRecipeTransferHandler(ContainerConstructionTable.class, LibModIntegrations.JEI.Recipes.ConstructionTable.getUid(), 1, 17, 18, 36);
recipeTransferRegistry.addRecipeTransferHandler(ContainerConstructionTable.class, VanillaRecipeCategoryUid.CRAFTING, 1, 9, 18, 36);
registry.addRecipeCategoryCraftingItem(new ItemStack(ModBlocks.ConstructionTable), LibModIntegrations.JEI.Recipes.ConstructionTable.getUid());
registry.addRecipeCategoryCraftingItem(new ItemStack(ModBlocks.ConstructionTable), VanillaRecipeCategoryUid.CRAFTING);
}
}