mezz.jei.api.gui.IRecipeLayout Java Examples

The following examples show how to use mezz.jei.api.gui.IRecipeLayout. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: FluidCraftingCategory.java    From Wizardry with GNU Lesser General Public License v3.0 6 votes vote down vote up
@Override
public void setRecipe(@Nonnull IRecipeLayout recipeLayout, @Nonnull FluidRecipeJEI recipeWrapper, @Nonnull IIngredients ingredients) {
	recipeLayout.getItemStacks().init(0, true, 0, 13);
	recipeLayout.getFluidStacks().init(0, true, 30, 14);

	recipeLayout.getItemStacks().init(1, true, 11, 46);
	recipeLayout.getItemStacks().init(2, true, 29, 46);
	recipeLayout.getItemStacks().init(3, true, 47, 46);
	recipeLayout.getItemStacks().init(4, true, 11, 64);
	recipeLayout.getItemStacks().init(5, true, 29, 64);
	recipeLayout.getItemStacks().init(6, true, 47, 64);
	recipeLayout.getItemStacks().init(7, true, 11, 82);
	recipeLayout.getItemStacks().init(8, true, 29, 82);
	recipeLayout.getItemStacks().init(9, true, 47, 82);


	if (recipeWrapper.isFluidOutput())
		recipeLayout.getFluidStacks().init(1, false, 59, 14);
	else
		recipeLayout.getItemStacks().init(10, false, 58, 13);

	recipeLayout.getItemStacks().set(ingredients);
	recipeLayout.getFluidStacks().set(ingredients);
}
 
Example #2
Source File: OreByProductCategory.java    From GregTech with GNU Lesser General Public License v3.0 6 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, OreByProduct recipeWrapper, IIngredients ingredients) {
	IGuiItemStackGroup itemStackGroup = recipeLayout.getItemStacks();
	itemStackGroup.init(0, true,  22,  29); //Ore
	itemStackGroup.init(1, true,  70,  19); //Crushed
	itemStackGroup.init(2, true,  88,  19); //Crushed Prurified
	itemStackGroup.init(3, true, 106,  19); //Crushed Centfiguged
	itemStackGroup.init(4, true,  70,  37); //Dust Impure
	itemStackGroup.init(5, true,  88,  37); //Dust Purified
	itemStackGroup.init(6, true, 106,  37); //Dust
	
	for(int i = 0; i < recipeWrapper.getOutputCount();i++)
		itemStackGroup.init(i + 7, false, 70 + (i * 18), 59);
	
	itemStackGroup.addTooltipCallback(recipeWrapper::addTooltip);
	itemStackGroup.set(ingredients);
}
 
Example #3
Source File: ModularUIGuiHandler.java    From GregTech with GNU Lesser General Public License v3.0 6 votes vote down vote up
@Nullable
@Override
public IRecipeTransferError transferRecipe(ModularUIContainer container, IRecipeLayout recipeLayout, EntityPlayer player, boolean maxTransfer, boolean doTransfer) {
    Optional<IRecipeTransferHandlerWidget> transferHandler = container.getModularUI()
        .guiWidgets.values().stream()
        .filter(it -> it instanceof IRecipeTransferHandlerWidget)
        .map(it -> (IRecipeTransferHandlerWidget) it)
        .findFirst();
    if (!transferHandler.isPresent()) {
        return transferHelper.createInternalError();
    }
    Map<Integer, IGuiIngredient<ItemStack>> group = new HashMap<>(recipeLayout.getItemStacks().getGuiIngredients());
    group.values().removeIf(it -> it.getAllIngredients().isEmpty());
    String errorTooltip = transferHandler.get().transferRecipe(container, group, player, maxTransfer, doTransfer);
    if (errorTooltip == null) {
        return null;
    }
    return transferHelper.createUserErrorWithTooltip(errorTooltip);
}
 
Example #4
Source File: GTJeiMagicFuelCategory.java    From GT-Classic with GNU Lesser General Public License v3.0 6 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout layout, GTJeiMagicFuelWrapper wrapper, IIngredients ingredients) {
	IGuiItemStackGroup itemGroup = layout.getItemStacks();
	IGuiFluidStackGroup fluidGroup = layout.getFluidStacks();
	int index = 0;
	int actualIndex = 0;
	for (IRecipeInput list : wrapper.getMultiRecipe().getInputs()) {
		int x = index % 3;
		int y = index / 3;
		if (list instanceof RecipeInputFluid) {
			fluidGroup.init(actualIndex, true, (18 * x) + 1, (18 * y)
					+ 1, 16, 16, ((RecipeInputFluid) list).fluid.amount, true, null);
			fluidGroup.set(actualIndex, ((RecipeInputFluid) list).fluid);
		} else {
			itemGroup.init(actualIndex, true, (18 * x), (18 * y));
			itemGroup.set(actualIndex, list.getInputs());
		}
		index++;
		actualIndex++;
		if (index >= 6) {
			break;
		}
	}
}
 
Example #5
Source File: CraftingRecipeCategory.java    From customstuff4 with GNU General Public License v3.0 6 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, IRecipeWrapper recipeWrapper, IIngredients ingredients)
{
    super.setRecipe(recipeLayout, recipeWrapper, ingredients);

    IGuiItemStackGroup stacks = recipeLayout.getItemStacks();

    List<List<ItemStack>> inputItems = ingredients.getInputs(ItemStack.class);
    List<List<ItemStack>> outputItems = ingredients.getOutputs(ItemStack.class);

    initItems(stacks, true, module.rows * module.columns, 0);
    initItems(stacks, false, 1, module.rows * module.columns);

    if (recipeWrapper instanceof IShapedCraftingRecipeWrapper)
    {
        IShapedCraftingRecipeWrapper wrapper = (IShapedCraftingRecipeWrapper) recipeWrapper;
        craftingGridHelper.setInputs(stacks, inputItems, wrapper.getWidth(), wrapper.getHeight());
    } else
    {
        craftingGridHelper.setInputs(stacks, inputItems);
        recipeLayout.setShapeless();
    }

    stacks.set(module.rows * module.columns, outputItems.get(0));
}
 
Example #6
Source File: ProduceRecipeCategory.java    From AgriCraft with MIT License 6 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, ProduceRecipeWrapper recipeWrapper, IIngredients ingredients) {
    // Setup Inputs
    recipeLayout.getItemStacks().init(0, true, 15, 28);
    recipeLayout.getItemStacks().init(1, true, 15, 54);
    recipeLayout.getItemStacks().init(2, true, 15, 75);

    // Setup Outputs
    int index = 2;

    for (int y = 12; y < 62; y += 18) {
        for (int x = 74; x < 128; x += 18) {
            recipeLayout.getItemStacks().init(++index, false, x, y);
        }
    }

    // Set ItemStacks
    recipeLayout.getItemStacks().set(ingredients);
}
 
Example #7
Source File: CategoryPot.java    From Sakura_mod with MIT License 6 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout arg0, IRecipeWrapper arg1, IIngredients arg2) {
	IGuiItemStackGroup items = arg0.getItemStacks();
	
	items.init(0, true, 37, 11);
	int k,l;
    for (k = 1; k <5; ++k)
        items.init(k,true, 10 + (k-1) * 18, 29);
    for (l = 5; l <9; ++l)
       	items.init(l,true, 10 + (l-5) * 18, 47);
	items.init(9, false, 122, 38);
    
	items.set(arg2);
	IGuiFluidStackGroup fiuld = arg0.getFluidStacks();
	fiuld.init(0, true, 88, 4, 72, 16, arg2.getInputs(VanillaTypes.FLUID).get(0).get(0).amount, false, null);
	if(arg2.getInputs(VanillaTypes.FLUID).get(0).get(0)!=null&&arg2.getInputs(VanillaTypes.FLUID).get(0).get(0).amount>0)
	fiuld.set(0, arg2.getInputs(VanillaTypes.FLUID).get(0));
}
 
Example #8
Source File: BaseRecipeCategory.java    From customstuff4 with GNU General Public License v3.0 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, T recipeWrapper, IIngredients ingredients)
{
    if (recipe.transferButtonX >= 0 && recipe.transferButtonY >= 0)
    {
        recipeLayout.setRecipeTransferButton(recipe.transferButtonX - recipe.bgX, recipe.transferButtonY - recipe.bgY);
    }
}
 
Example #9
Source File: MutationRecipeCategory.java    From AgriCraft with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, MutationRecipeWrapper recipeWrapper, IIngredients ingredients) {
    recipeLayout.getItemStacks().init(0, true, 24, 39);
    recipeLayout.getItemStacks().init(1, true, 86, 39);
    recipeLayout.getItemStacks().init(2, true, 55, 65);
    recipeLayout.getItemStacks().init(3, true, 55, 86);
    recipeLayout.getItemStacks().init(4, false, 55, 39);
    recipeLayout.getItemStacks().set(ingredients);
}
 
Example #10
Source File: CokeOvenRecipeCategory.java    From GregTech with GNU Lesser General Public License v3.0 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, CokeOvenRecipeWrapper recipeWrapper, IIngredients ingredients) {
	IGuiItemStackGroup itemStackGroup = recipeLayout.getItemStacks();
	IGuiFluidStackGroup fluidStackGroup = recipeLayout.getFluidStacks();
	itemStackGroup.init(0, true, 32, 19);
	itemStackGroup.init(1, false, 84, 19);
	itemStackGroup.set(ingredients);
	fluidStackGroup.init(0, false, 133, 3, 20, 58, 32000, true, this.fluidTankOverlay);
	fluidStackGroup.set(ingredients);
}
 
Example #11
Source File: PrimitiveBlastRecipeCategory.java    From GregTech with GNU Lesser General Public License v3.0 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, PrimitiveBlastRecipeWrapper recipeWrapper,
		IIngredients ingredients) {
	IGuiItemStackGroup itemStackGroup = recipeLayout.getItemStacks();
	itemStackGroup.init(0, true, 32, 4);
	itemStackGroup.init(1, true, 32, 22);

	itemStackGroup.init(2, false, 84, 13);
	itemStackGroup.init(3, false, 102, 13);
	itemStackGroup.set(ingredients);
}
 
Example #12
Source File: JEICrusherRecipeCategory.java    From BaseMetals with GNU Lesser General Public License v2.1 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, IRecipeWrapper recipeWrapper) {
	IGuiItemStackGroup guiItemStacks = recipeLayout.getItemStacks();

	int x = 45, y = 7;
	guiItemStacks.init(inputSlot, true, x, y);
	guiItemStacks.init(outputSlot, false, x+58, y);

	guiItemStacks.setFromRecipe(inputSlot, recipeWrapper.getInputs());
	guiItemStacks.setFromRecipe(outputSlot, recipeWrapper.getOutputs());
}
 
Example #13
Source File: CustomRecipeCategory.java    From YouTubeModdingTutorial with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, CustomRecipeWrapper recipeWrapper, IIngredients ingredients) {
    IGuiItemStackGroup guiItemStacks = recipeLayout.getItemStacks();

    guiItemStacks.init(0, true, 6, 6);
    guiItemStacks.init(3, false, 114, 6);

    List<ItemStack> inputs = ingredients.getInputs(VanillaTypes.ITEM).get(0);
    List<ItemStack> outputs = ingredients.getOutputs(VanillaTypes.ITEM).get(0);

    guiItemStacks.set(0, inputs);
    guiItemStacks.set(3, outputs);
}
 
Example #14
Source File: FloadRecipeCategory.java    From YouTubeModdingTutorial with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, FloadRecipeWrapper recipeWrapper, IIngredients ingredients) {
    IGuiItemStackGroup guiItemStacks = recipeLayout.getItemStacks();
    IGuiFluidStackGroup guiFluidStacks = recipeLayout.getFluidStacks();

    guiFluidStacks.init(0, false, 65, 6, 18, 18, 100, true, null);
    guiItemStacks.init(0, true, 6, 6);

    List<ItemStack> inputs = ingredients.getInputs(VanillaTypes.ITEM).get(0);
    List<FluidStack> outputs = ingredients.getOutputs(VanillaTypes.FLUID).get(0);

    guiItemStacks.set(0, inputs);
    guiFluidStacks.set(0, outputs);
}
 
Example #15
Source File: CompostRecipeCategory.java    From ExNihiloAdscensio with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout layout, CompostRecipe recipe)
{
    // Block
    layout.getItemStacks().init(0, false, 74, 9);
    layout.getItemStacks().set(0, (ItemStack) recipe.getOutputs().get(0));
    
    IFocus<?> focus = layout.getFocus();
    boolean mightHaveHighlight = focus.getMode() == IFocus.Mode.INPUT;
    hasHighlight = false;

    ItemStack focusStack = (ItemStack) focus.getValue();
    
    int slotIndex = 1;
    
    for (int i = 0; i < recipe.getInputs().size(); i++)
    {
        final int slotX = 2 + (i % 9 * 18);
        final int slotY = 36 + (i / 9 * 18);
        
        ItemStack inputStack = (ItemStack) recipe.getInputs().get(i);
        
        layout.getItemStacks().init(slotIndex + i, true, slotX, slotY);
        layout.getItemStacks().set(slotIndex + i, inputStack);
        
        if (mightHaveHighlight && ItemStack.areItemsEqual(focusStack, inputStack))
        {
            highlightX = slotX;
            highlightY = slotY;
            
            hasHighlight = true;
            mightHaveHighlight = false;
        }
    }
    
    layout.getItemStacks().addTooltipCallback(new CompostTooltipCallback());
}
 
Example #16
Source File: MachineRecipeCategory.java    From customstuff4 with GNU General Public License v3.0 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, MachineRecipeWrapper recipeWrapper, IIngredients ingredients)
{
    super.setRecipe(recipeLayout, recipeWrapper, ingredients);

    IGuiItemStackGroup stacks = recipeLayout.getItemStacks();
    IGuiFluidStackGroup fluids = recipeLayout.getFluidStacks();

    List<List<ItemStack>> inputItems = ingredients.getInputs(ItemStack.class);
    List<List<FluidStack>> inputFluids = ingredients.getInputs(FluidStack.class);
    List<List<ItemStack>> outputItems = ingredients.getOutputs(ItemStack.class);
    List<List<FluidStack>> outputFluids = ingredients.getOutputs(FluidStack.class);

    initItems(stacks, true, module.inputSlots, 0);
    initItems(stacks, false, module.outputSlots, module.inputSlots);

    initFluids(fluids, true, module.inputTanks, 0);
    initFluids(fluids, false, module.outputTanks, module.inputTanks.length);

    for (int i = 0; i < inputItems.size(); i++)
    {
        stacks.set(i, inputItems.get(i));
    }

    for (int i = 0; i < outputItems.size(); i++)
    {
        stacks.set(module.inputSlots + i, outputItems.get(i));
    }

    for (int i = 0; i < inputFluids.size(); i++)
    {
        fluids.set(i, inputFluids.get(i));
    }

    for (int i = 0; i < outputFluids.size(); i++)
    {
        fluids.set(module.inputTanks.length + i, outputFluids.get(i));
    }
}
 
Example #17
Source File: CategoryCrusher.java    From TofuCraftReload with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout arg0, IRecipeWrapper arg1, IIngredients arg2) {
	IGuiItemStackGroup items = arg0.getItemStacks();
	
	items.init(0, true, 4, 4);
	items.init(1, false, 74, 4);
    
	items.set(arg2);
}
 
Example #18
Source File: FireCraftingCategory.java    From Wizardry with GNU Lesser General Public License v3.0 5 votes vote down vote up
@Override
public void setRecipe(@Nonnull IRecipeLayout recipeLayout, @Nonnull FireRecipeJEI recipeWrapper, @Nonnull IIngredients ingredients) {
	recipeLayout.getItemStacks().init(0, true, 0, 13);
	recipeLayout.getItemStacks().init(1, false, 58, 13);

	recipeLayout.getItemStacks().set(ingredients);
}
 
Example #19
Source File: HammerRecipeCategory.java    From ExNihiloAdscensio with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, HammerRecipe recipeWrapper)
{
    // Block
    recipeLayout.getItemStacks().init(0, true, 74, 9);
    recipeLayout.getItemStacks().set(0, (ItemStack) recipeWrapper.getInputs().get(0));
    
    IFocus<?> focus = recipeLayout.getFocus();
    hasHighlight = focus.getMode() == IFocus.Mode.OUTPUT;
    
    int slotIndex = 1;
    
    for (int i = 0; i < recipeWrapper.getOutputs().size(); i++)
    {
        final int slotX = 2 + (i % 9 * 18);
        final int slotY = 36 + (i / 9 * 18);
        
        ItemStack outputStack = (ItemStack) recipeWrapper.getOutputs().get(i);
        
        recipeLayout.getItemStacks().init(slotIndex + i, false, slotX, slotY);
        recipeLayout.getItemStacks().set(slotIndex + i, outputStack);
        
        ItemStack focusStack = (ItemStack) focus.getValue();
        
        if (focus.getMode() == IFocus.Mode.OUTPUT && focusStack != null && focusStack.getItem() == outputStack.getItem() && focusStack.getItemDamage() == outputStack.getItemDamage())
        {
            highlightX = slotX;
            highlightY = slotY;
        }
    }
    
    recipeLayout.getItemStacks().addTooltipCallback(new HammerTooltipCallback(recipeWrapper));
}
 
Example #20
Source File: FluidBlockTransformRecipeCategory.java    From ExNihiloAdscensio with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, FluidBlockTransformRecipe recipeWrapper)
{
    recipeLayout.getItemStacks().init(0, true, 74, 36);
    recipeLayout.getItemStacks().init(1, true, 47, 36);
    recipeLayout.getItemStacks().init(2, true, 74, 9);
    recipeLayout.getItemStacks().init(3, false, 101, 36);
    
    recipeLayout.getItemStacks().set(0, new ItemStack(ENBlocks.barrelStone, 1, 0));
    recipeLayout.getItemStacks().set(1, recipeWrapper.getInputs().get(0));
    recipeLayout.getItemStacks().set(2, recipeWrapper.getInputs().get(1));
    recipeLayout.getItemStacks().set(3, recipeWrapper.getOutputs().get(0));
}
 
Example #21
Source File: FluidTransformRecipeCategory.java    From ExNihiloAdscensio with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, FluidTransformRecipe recipeWrapper)
{
    recipeLayout.getItemStacks().init(0, true, 74, 9);
    recipeLayout.getItemStacks().init(1, true, 47, 9);
    recipeLayout.getItemStacks().init(2, true, 74, 36);
    recipeLayout.getItemStacks().init(3, false, 101, 9);
    
    boolean noCycle = false;
    List<ItemStack> focusStack = null;
    
    IFocus<?> focus = recipeLayout.getFocus();
    
    if(focus.getMode() == IFocus.Mode.INPUT && focus.getValue() instanceof ItemStack)
    {
        ItemStack stack = (ItemStack) focus.getValue();
        
        for(ItemStack inputStack : recipeWrapper.getInputs().subList(1, recipeWrapper.getInputs().size()))
        {
            if(stack.isItemEqual(inputStack))
            {
                noCycle = true;
                focusStack = ImmutableList.of(inputStack);
            }
        }
    }
    
    recipeLayout.getItemStacks().set(0, new ItemStack(ENBlocks.barrelStone, 1, 0));
    recipeLayout.getItemStacks().set(1, recipeWrapper.getInputs().get(0));
    recipeLayout.getItemStacks().set(2, noCycle ? focusStack : ImmutableList.copyOf(recipeWrapper.getInputs().subList(1, recipeWrapper.getInputs().size())));
    recipeLayout.getItemStacks().set(3, recipeWrapper.getOutputs().get(0));
}
 
Example #22
Source File: FluidOnTopRecipeCategory.java    From ExNihiloAdscensio with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, FluidOnTopRecipe recipeWrapper)
{
    recipeLayout.getItemStacks().init(0, true, 74, 36);
    recipeLayout.getItemStacks().init(1, true, 47, 36);
    recipeLayout.getItemStacks().init(2, true, 74, 9);
    recipeLayout.getItemStacks().init(3, false, 101, 36);
    
    recipeLayout.getItemStacks().set(0, new ItemStack(ENBlocks.barrelStone, 1, 0));
    recipeLayout.getItemStacks().set(1, recipeWrapper.getInputs().get(0));
    recipeLayout.getItemStacks().set(2, recipeWrapper.getInputs().get(1));
    recipeLayout.getItemStacks().set(3, recipeWrapper.getOutputs().get(0));
}
 
Example #23
Source File: ScrubberCategory.java    From EmergingTechnology with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout recipeLayout, ScrubberRecipeWrapper recipeWrapper, IIngredients ingredients)
{
    IGuiItemStackGroup guiStacks = recipeLayout.getItemStacks();

    guiStacks.init(INPUT_SLOT, true, 16, 34);
    guiStacks.init(OUTPUT_SLOT, false, 79, 34);

    guiStacks.set(ingredients);
}
 
Example #24
Source File: CategoryCompressor.java    From TofuCraftReload with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout arg0, IRecipeWrapper arg1, IIngredients arg2) {
	IGuiItemStackGroup items = arg0.getItemStacks();
	
	items.init(0, true, 4, 4);
	items.init(1, false, 74, 4);
    
	items.set(arg2);
}
 
Example #25
Source File: CategoryAggregator.java    From TofuCraftReload with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout arg0, IRecipeWrapper arg1, IIngredients arg2) {
	IGuiItemStackGroup items = arg0.getItemStacks();
	
	items.init(0, true, 4, 4);
	items.init(1, false, 74, 4);
    
	items.set(arg2);
}
 
Example #26
Source File: CategoryAdvancedAggregator.java    From TofuCraftReload with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout arg0, IRecipeWrapper arg1, IIngredients arg2) {
	IGuiItemStackGroup items = arg0.getItemStacks();
	
	items.init(0, true, 5, 5);
	items.init(1, true, 25, 5);
	items.init(2, true, 5, 25);
	items.init(3, true, 25, 25);
	items.init(4, false, 75, 15);
    
	items.set(arg2);
}
 
Example #27
Source File: CategoryL2IS.java    From Sakura_mod with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout arg0, IRecipeWrapper arg1, IIngredients arg2) {
	IGuiItemStackGroup items = arg0.getItemStacks();
	items.init(0, true, 13, 14);
	items.init(1, false, 62, 14);
	items.set(arg2);
	IGuiFluidStackGroup fiuld = arg0.getFluidStacks();
	fiuld.init(0, true, 14, 47, 65, 20, arg2.getInputs(VanillaTypes.FLUID).get(0).get(0).amount, false, null);
	fiuld.set(0, arg2.getInputs(VanillaTypes.FLUID).get(0));
}
 
Example #28
Source File: CategoryDistillation.java    From Sakura_mod with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout arg0, IRecipeWrapper arg1, IIngredients arg2) {
	IGuiItemStackGroup items = arg0.getItemStacks();
    items.init(0,true, 29, 13);
    items.init(1,true, 29, 31);
    items.init(2,true, 29, 49);
	items.set(arg2);
	IGuiFluidStackGroup fiuld = arg0.getFluidStacks();
	fiuld.init(0, true, 6, 6, 16, 68, arg2.getInputs(VanillaTypes.FLUID).get(0).get(0).amount, false, null);
	fiuld.set(0, arg2.getInputs(VanillaTypes.FLUID).get(0));
	fiuld.init(1, false, 77, 6, 16, 68, arg2.getOutputs(VanillaTypes.FLUID).get(0).get(0).amount, false, null);
	fiuld.set(1, arg2.getOutputs(VanillaTypes.FLUID).get(0));
}
 
Example #29
Source File: CategoryMortar.java    From Sakura_mod with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout arg0, IRecipeWrapper arg1, IIngredients arg2) {
	IGuiItemStackGroup items = arg0.getItemStacks();
	
	items.init(0, true, 1, 1);
	items.init(1, true, 19, 1);
	items.init(2, true, 1, 19);
	items.init(3, true, 19, 19);
	items.init(4, false, 69, 12);
	items.init(5, false, 93, 12);
    
	items.set(arg2);
}
 
Example #30
Source File: CategoryBarrel.java    From Sakura_mod with MIT License 5 votes vote down vote up
@Override
public void setRecipe(IRecipeLayout arg0, IRecipeWrapper arg1, IIngredients arg2) {
	IGuiItemStackGroup items = arg0.getItemStacks();
    items.init(0,true, 29, 13);
    items.init(1,true, 29, 31);
    items.init(2,true, 29, 49);
	items.set(arg2);
	IGuiFluidStackGroup fiuld = arg0.getFluidStacks();
	fiuld.init(0, true, 6, 6, 16, 68, arg2.getInputs(VanillaTypes.FLUID).get(0).get(0).amount, false, null);
	fiuld.set(0, arg2.getInputs(VanillaTypes.FLUID).get(0));
	fiuld.init(1, false, 77, 6, 16, 68, arg2.getOutputs(VanillaTypes.FLUID).get(0).get(0).amount, false, null);
	fiuld.set(1, arg2.getOutputs(VanillaTypes.FLUID).get(0));
}