/
FurnaceRecipeCategory.java
28 lines (22 loc) · 1.24 KB
/
FurnaceRecipeCategory.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
package mezz.jei.plugins.vanilla.furnace;
import mezz.jei.api.IGuiHelper;
import mezz.jei.api.gui.IDrawableAnimated;
import mezz.jei.api.gui.IDrawableStatic;
import mezz.jei.api.recipe.BlankRecipeCategory;
import mezz.jei.api.recipe.IRecipeWrapper;
import net.minecraft.util.ResourceLocation;
public abstract class FurnaceRecipeCategory<T extends IRecipeWrapper> extends BlankRecipeCategory<T> {
protected static final int inputSlot = 0;
protected static final int fuelSlot = 1;
protected static final int outputSlot = 2;
protected final ResourceLocation backgroundLocation;
protected final IDrawableAnimated flame;
protected final IDrawableAnimated arrow;
public FurnaceRecipeCategory(IGuiHelper guiHelper) {
backgroundLocation = new ResourceLocation("minecraft", "textures/gui/container/furnace.png");
IDrawableStatic flameDrawable = guiHelper.createDrawable(backgroundLocation, 176, 0, 14, 14);
flame = guiHelper.createAnimatedDrawable(flameDrawable, 300, IDrawableAnimated.StartDirection.TOP, true);
IDrawableStatic arrowDrawable = guiHelper.createDrawable(backgroundLocation, 176, 14, 24, 17);
this.arrow = guiHelper.createAnimatedDrawable(arrowDrawable, 200, IDrawableAnimated.StartDirection.LEFT, false);
}
}