Search in sources :

Example 1 with IntCircuitRecipeBuilder

use of gregtech.api.recipes.builders.IntCircuitRecipeBuilder in project GregTech by GregTechCE.

the class RecipeMap method getOverlaysForSlot.

protected TextureArea[] getOverlaysForSlot(boolean isOutput, boolean isFluid, boolean isLast) {
    TextureArea base = isFluid ? GuiTextures.FLUID_SLOT : GuiTextures.SLOT;
    if (!isOutput && !isFluid && isLast && recipeBuilderSample instanceof IntCircuitRecipeBuilder) {
        // automatically add int circuit overlay to last item input slot
        return new TextureArea[] { base, GuiTextures.INT_CIRCUIT_OVERLAY };
    }
    byte overlayKey = (byte) ((isOutput ? 2 : 0) + (isFluid ? 1 : 0) + (isLast ? 4 : 0));
    if (slotOverlays.containsKey(overlayKey)) {
        return new TextureArea[] { base, slotOverlays.get(overlayKey) };
    }
    return new TextureArea[] { base };
}
Also used : TextureArea(gregtech.api.gui.resources.TextureArea) IntCircuitRecipeBuilder(gregtech.api.recipes.builders.IntCircuitRecipeBuilder)

Aggregations

TextureArea (gregtech.api.gui.resources.TextureArea)1 IntCircuitRecipeBuilder (gregtech.api.recipes.builders.IntCircuitRecipeBuilder)1