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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
|
package ihl.nei_integration;
import java.awt.Rectangle;
import java.util.Map;
import org.lwjgl.opengl.GL11;
import codechicken.lib.gui.GuiDraw;
import ihl.processing.chemistry.ChemicalReactorGui;
import ihl.processing.chemistry.ChemicalReactorTileEntity;
import ihl.recipes.UniversalRecipeInput;
import ihl.recipes.UniversalRecipeOutput;
import net.minecraft.client.gui.inventory.GuiContainer;
import net.minecraft.util.StatCollector;
public class ChemicalReactorRecipeHandler extends MachineRecipeHandler
{
@Override
public Class <? extends GuiContainer > getGuiClass()
{
return ChemicalReactorGui.class;
}
@Override
protected int[] getInputPosX()
{
return new int[]{104-5,122-5};
}
@Override
protected int[] getInputPosY()
{
return new int[]{15-11};
}
@Override
protected int[] getFluidInputPosX()
{
return new int[]{60-5,42-5,24-5};
}
@Override
protected int[] getFluidInputPosY()
{
return new int[]{15-11};
}
@Override
protected int[] getOutputPosX()
{
return new int[]{104-5,122-5};
}
@Override
protected int[] getFluidOutputPosX()
{
return new int[]{42-5,60-5};
}
@Override
protected int[] getOutputPosY()
{
return new int[]{51-11};
}
@Override
protected int[] getFluidOutputPosY()
{
return new int[]{51-11};
}
@Override
public String getRecipeId()
{
return "ihl.chemicalReactor";
}
@Override
public String getGuiTexture()
{
return "ihl:textures/gui/GUIChemicalReactor.png";
}
@Override
public String getOverlayIdentifier()
{
return "chemicalReactor";
}
@Override
public void loadTransferRects()
{
this.transferRects.add(new RecipeTransferRect(new Rectangle(103-5,32-10, 36, 18), this.getRecipeId(), new Object[0]));
}
@Override
public void drawExtras(int recipeNumber)
{
super.drawExtras(recipeNumber);
MachineRecipeHandler.CachedIORecipe recipe = (CachedIORecipe) this.arecipes.get(recipeNumber);
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
GuiDraw.drawTexturedModalRect(103-18-5, 52-11, 246, 226+6*(this.ticks%4),10,6);
if(recipe.specialConditions)
{
GuiDraw.drawTexturedModalRect(0, 32-11, 0, 166,134,18);
GuiDraw.fontRenderer.drawStringWithShadow(StatCollector.translateToLocal("ihl.use_with_cryogenic_distiller"), 0, 27, 16777215);
}
}
@Override
public void drawBackground(int i)
{
super.drawBackground(i);
GuiDraw.drawTexturedModalRect(23-5, 14-11, 59, 14, 18, 18);
GuiDraw.drawTexturedModalRect(41-5, 14-11, 59, 14, 18, 18);
GuiDraw.drawTexturedModalRect(41-5, 50-11, 59, 50, 18, 18);
}
@Override
public Map<UniversalRecipeInput, UniversalRecipeOutput> getRecipeList()
{
return ChemicalReactorTileEntity.getRecipes();
}
}
|