aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTechnus <daniel112092@gmail.com>2017-08-14 13:29:58 +0200
committerTechnus <daniel112092@gmail.com>2017-08-14 13:47:41 +0200
commit8802433234e2b36867c6d4d10d32e76fbf57b6a6 (patch)
tree2538c0bf65ca07cd9d67d30b13fbb1f2c926e8ba /src
parent5ba86b9b07bb124705fa0d2dd4c0da0ead643afa (diff)
downloadGT5-Unofficial-8802433234e2b36867c6d4d10d32e76fbf57b6a6.tar.gz
GT5-Unofficial-8802433234e2b36867c6d4d10d32e76fbf57b6a6.tar.bz2
GT5-Unofficial-8802433234e2b36867c6d4d10d32e76fbf57b6a6.zip
Work on some texture and change the research station behaviour a bit
Diffstat (limited to 'src')
-rw-r--r--src/main/java/com/github/technus/tectech/nei/TT_NEI_ResearchHandler.java900
-rw-r--r--src/main/java/com/github/technus/tectech/recipe/TT_recipe.java2
-rw-r--r--src/main/java/com/github/technus/tectech/recipe/TT_recipeAdder.java14
-rw-r--r--src/main/java/com/github/technus/tectech/thing/metaTileEntity/multi/GT_MetaTileEntity_EM_research.java6
-rw-r--r--src/main/resources/assets/gregtech/textures/gui/multimachines/ResearchFake.pngbin0 -> 1972 bytes
5 files changed, 453 insertions, 469 deletions
diff --git a/src/main/java/com/github/technus/tectech/nei/TT_NEI_ResearchHandler.java b/src/main/java/com/github/technus/tectech/nei/TT_NEI_ResearchHandler.java
index 64dfb900da..ac488e833a 100644
--- a/src/main/java/com/github/technus/tectech/nei/TT_NEI_ResearchHandler.java
+++ b/src/main/java/com/github/technus/tectech/nei/TT_NEI_ResearchHandler.java
@@ -13,7 +13,6 @@ import com.github.technus.tectech.TecTech;
import com.github.technus.tectech.auxiliary.Reference;
import com.github.technus.tectech.recipe.TT_recipe;
import cpw.mods.fml.common.event.FMLInterModComms;
-import gregtech.GT_Mod;
import gregtech.api.enums.OrePrefixes;
import gregtech.api.gui.GT_GUIContainer_BasicMachine;
import gregtech.api.objects.ItemData;
@@ -176,7 +175,7 @@ public class TT_NEI_ResearchHandler extends TemplateRecipeHandler {
}
public List<String> handleItemTooltip(GuiRecipe gui, ItemStack aStack, List<String> currenttip, int aRecipeIndex) {
- TemplateRecipeHandler.CachedRecipe tObject = (TemplateRecipeHandler.CachedRecipe) this.arecipes.get(aRecipeIndex);
+ TemplateRecipeHandler.CachedRecipe tObject = this.arecipes.get(aRecipeIndex);
if ((tObject instanceof CachedDefaultRecipe)) {
CachedDefaultRecipe tRecipe = (CachedDefaultRecipe) tObject;
for (PositionedStack tStack : tRecipe.mOutputs) {
@@ -207,32 +206,21 @@ public class TT_NEI_ResearchHandler extends TemplateRecipeHandler {
int computation = ((CachedDefaultRecipe) this.arecipes.get(aRecipeIndex)).mRecipe.mDuration;
String[] recipeDesc = ((CachedDefaultRecipe) this.arecipes.get(aRecipeIndex)).mRecipe.getNeiDesc();
if (recipeDesc == null) {
+ int tSpecial = ((CachedDefaultRecipe) this.arecipes.get(aRecipeIndex)).mRecipe.mSpecialValue;
+ short ampere=(short) (tSpecial & 0xFFFF),minComputationPerSec=(short)(tSpecial>>>16);
if (tEUt != 0) {
//drawText(10, 73, trans("152","Total: ") + computation * tEUt + " EU", -16777216);
- drawText(10, 83, trans("153","Usage: ") + tEUt + " EU/t", -16777216);
+ drawText(10, 83, trans("153","Usage: ") + ((long)tEUt*ampere) + " EU/t", -16777216);
if (this.mRecipeMap.mShowVoltageAmperageInNEI) {
- drawText(10, 93, trans("154","Voltage: ") + tEUt / this.mRecipeMap.mAmperage + " EU", -16777216);
- drawText(10, 103, trans("155","Amperage: ") + this.mRecipeMap.mAmperage, -16777216);
+ drawText(10, 93, trans("154","Voltage: ") + tEUt + " EU", -16777216);
+ drawText(10, 103, trans("155","Amperage: ") + ampere, -16777216);
} else {
drawText(10, 93, trans("156","Voltage: unspecified"), -16777216);
drawText(10, 103, trans("157","Amperage: unspecified"), -16777216);
}
}
- if (computation > 0) {
- drawText(10, 113, "Computation: "+computation, -16777216);
- }
- int tSpecial = ((CachedDefaultRecipe) this.arecipes.get(aRecipeIndex)).mRecipe.mSpecialValue;
- if (tSpecial == -100 && GT_Mod.gregtechproxy.mLowGravProcessing) {
- drawText(10, 123, trans("159","Needs Low Gravity"), -16777216);
- } else if (tSpecial == -200 && GT_Mod.gregtechproxy.mEnableCleanroom) {
- drawText(10, 123, trans("160","Needs Cleanroom"), -16777216);
- } else if (tSpecial == -300 && GT_Mod.gregtechproxy.mEnableCleanroom) {
- drawText(10, 123, trans("160","Needs Cleanroom & LowGrav"), -16777216);
- } else if (tSpecial == -400) {
- drawText(10, 123, trans("161", "Circuit slot can be left empty"), -16777216);
- } else if ((GT_Utility.isStringValid(this.mRecipeMap.mNEISpecialValuePre)) || (GT_Utility.isStringValid(this.mRecipeMap.mNEISpecialValuePost))) {
- drawText(10, 123, this.mRecipeMap.mNEISpecialValuePre + tSpecial * this.mRecipeMap.mNEISpecialValueMultiplier + this.mRecipeMap.mNEISpecialValuePost, -16777216);
- }
+ drawText(10, 113, "Computation: "+computation, -16777216);
+ drawText(10, 123, "min. Computation/s: "+minComputationPerSec, -16777216);
} else {
int i = 0;
for (String descLine : recipeDesc) {
@@ -278,9 +266,9 @@ public class TT_NEI_ResearchHandler extends TemplateRecipeHandler {
private boolean transferRect(GuiContainer gui, boolean usage) {
if (gui instanceof GT_GUIContainer_BasicMachine) {
- return (canHandle(gui)) && (new Rectangle(65, 13, 36, 18).contains(new Point(GuiDraw.getMousePosition().x - ((GT_GUIContainer_BasicMachine) gui).getLeft() - codechicken.nei.recipe.RecipeInfo.getGuiOffset(gui)[0], GuiDraw.getMousePosition().y - ((GT_GUIContainer_BasicMachine) gui).getTop() - codechicken.nei.recipe.RecipeInfo.getGuiOffset(gui)[1]))) && (usage ? GuiUsageRecipe.openRecipeGui(((GT_GUIContainer_BasicMachine) gui).mNEI, new Object[0]) : GuiCraftingRecipe.openRecipeGui(((GT_GUIContainer_BasicMachine) gui).mNEI, new Object[0]));
+ return (canHandle(gui)) && (new Rectangle(65, 13, 36, 18).contains(new Point(GuiDraw.getMousePosition().x - ((GT_GUIContainer_BasicMachine) gui).getLeft() - codechicken.nei.recipe.RecipeInfo.getGuiOffset(gui)[0], GuiDraw.getMousePosition().y - ((GT_GUIContainer_BasicMachine) gui).getTop() - codechicken.nei.recipe.RecipeInfo.getGuiOffset(gui)[1]))) && (usage ? GuiUsageRecipe.openRecipeGui(((GT_GUIContainer_BasicMachine) gui).mNEI) : GuiCraftingRecipe.openRecipeGui(((GT_GUIContainer_BasicMachine) gui).mNEI));
} else if (gui instanceof GT_GUIContainer_FusionReactor) {
- return (canHandle(gui)) && (new Rectangle(145, 0, 24, 24).contains(new Point(GuiDraw.getMousePosition().x - ((GT_GUIContainer_FusionReactor) gui).getLeft() - codechicken.nei.recipe.RecipeInfo.getGuiOffset(gui)[0], GuiDraw.getMousePosition().y - ((GT_GUIContainer_FusionReactor) gui).getTop() - codechicken.nei.recipe.RecipeInfo.getGuiOffset(gui)[1]))) && (usage ? GuiUsageRecipe.openRecipeGui(((GT_GUIContainer_FusionReactor) gui).mNEI, new Object[0]) : GuiCraftingRecipe.openRecipeGui(((GT_GUIContainer_FusionReactor) gui).mNEI, new Object[0]));
+ return (canHandle(gui)) && (new Rectangle(145, 0, 24, 24).contains(new Point(GuiDraw.getMousePosition().x - ((GT_GUIContainer_FusionReactor) gui).getLeft() - codechicken.nei.recipe.RecipeInfo.getGuiOffset(gui)[0], GuiDraw.getMousePosition().y - ((GT_GUIContainer_FusionReactor) gui).getTop() - codechicken.nei.recipe.RecipeInfo.getGuiOffset(gui)[1]))) && (usage ? GuiUsageRecipe.openRecipeGui(((GT_GUIContainer_FusionReactor) gui).mNEI) : GuiCraftingRecipe.openRecipeGui(((GT_GUIContainer_FusionReactor) gui).mNEI));
}
return false;
}
@@ -341,7 +329,7 @@ public class TT_NEI_ResearchHandler extends TemplateRecipeHandler {
List<ItemStack> permutations = codechicken.nei.ItemList.itemMap.get(tStack.getItem());
if (!permutations.isEmpty()) {
ItemStack stack;
- for (Iterator i$ = permutations.iterator(); i$.hasNext(); tDisplayStacks.add(GT_Utility.copyAmount(tStack.stackSize, new Object[]{stack}))) {
+ for (Iterator i$ = permutations.iterator(); i$.hasNext(); tDisplayStacks.add(GT_Utility.copyAmount(tStack.stackSize, stack))) {
stack = (ItemStack) i$.next();
}
} else {
@@ -350,11 +338,11 @@ public class TT_NEI_ResearchHandler extends TemplateRecipeHandler {
tDisplayStacks.add(base);
}
} else {
- tDisplayStacks.add(GT_Utility.copy(new Object[]{tStack}));
+ tDisplayStacks.add(GT_Utility.copy(tStack));
}
}
}
- this.items = ((ItemStack[]) tDisplayStacks.toArray(new ItemStack[0]));
+ this.items = tDisplayStacks.toArray(new ItemStack[0]);
if (this.items.length == 0) {
this.items = new ItemStack[]{new ItemStack(Blocks.fire)};
}
@@ -372,448 +360,442 @@ public class TT_NEI_ResearchHandler extends TemplateRecipeHandler {
public CachedDefaultRecipe(GT_Recipe aRecipe) {
super();
this.mRecipe = aRecipe;
-
- if (aRecipe.getInputPositionedStacks() != null && aRecipe.getOutputPositionedStacks() != null) {
- mInputs = aRecipe.getInputPositionedStacks();
- mOutputs = aRecipe.getOutputPositionedStacks();
- return;
- }
mOutputs = new ArrayList<>();
mInputs = new ArrayList<>();
int tStartIndex = 0;
- switch (mRecipeMap.mUsualInputCount) {
- case 0:
- break;
- case 1:
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
- }
- tStartIndex++;
- break;
- case 2:
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
- }
- tStartIndex++;
- break;
- case 3:
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
- }
- tStartIndex++;
- break;
- case 4:
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 5));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 5));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 23));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 23));
- }
- tStartIndex++;
- break;
- case 5:
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 5));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 5));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 5));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 23));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 23));
- }
- tStartIndex++;
- break;
- case 6:
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 5));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 5));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 5));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 23));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 23));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 23));
- }
- tStartIndex++;
- break;
- case 7:
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, -4));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, -4));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, -4));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 32));
- }
- tStartIndex++;
- break;
- case 8:
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, -4));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, -4));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, -4));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 32));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 32));
- }
- tStartIndex++;
- break;
- default:
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, -4));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, -4));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, -4));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 32));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 32));
- }
- tStartIndex++;
- if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
- this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 32));
- }
- tStartIndex++;
- }
+ //switch (mRecipeMap.mUsualInputCount) {
+ //case 0:
+ // break;
+ //case 1:
+ if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14+9));
+ }
+ //tStartIndex++;
+ //break;
+ //case 2:
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
+ // }
+ // tStartIndex++;
+ // break;
+ //case 3:
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
+ // }
+ // tStartIndex++;
+ // break;
+ //case 4:
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 5));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 5));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 23));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 23));
+ // }
+ // tStartIndex++;
+ // break;
+ //case 5:
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 5));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 5));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 5));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 23));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 23));
+ // }
+ // tStartIndex++;
+ // break;
+ //case 6:
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 5));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 5));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 5));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 23));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 23));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 23));
+ // }
+ // tStartIndex++;
+ // break;
+ //case 7:
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, -4));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, -4));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, -4));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 32));
+ // }
+ // tStartIndex++;
+ // break;
+ //case 8:
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, -4));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, -4));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, -4));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 32));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 32));
+ // }
+ // tStartIndex++;
+ // break;
+ //default:
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, -4));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, -4));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, -4));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 14));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 12, 32));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 30, 32));
+ // }
+ // tStartIndex++;
+ // if (aRecipe.getRepresentativeInput(tStartIndex) != null) {
+ // this.mInputs.add(new FixedPositionedStack(aRecipe.getRepresentativeInput(tStartIndex), 48, 32));
+ // }
+ // tStartIndex++;
+ //}
if (aRecipe.mSpecialItems != null) {
this.mInputs.add(new FixedPositionedStack(aRecipe.mSpecialItems, 120, 52));
}
- tStartIndex = 0;
- switch (mRecipeMap.mUsualOutputCount) {
- case 0:
- break;
- case 1:
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 14, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- break;
- case 2:
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 14, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 120, 14, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- break;
- case 3:
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 14, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 120, 14, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 138, 14, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- break;
- case 4:
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 5, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 120, 5, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 23, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 120, 23, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- break;
- case 5:
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 5, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 120, 5, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 138, 5, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 23, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 120, 23, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- break;
- case 6:
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 5, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 120, 5, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 138, 5, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 23, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 120, 23, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 138, 23, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- break;
- case 7:
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, -4, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 120, -4, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 138, -4, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 14, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 120, 14, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 138, 14, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartIndex++;
- if (aRecipe.getOutput(tStartIndex) != null) {
- this.mOutputs.add(new FixedPositionedStack(aRecipe.getOutput(tStartIndex), 102, 32, aRecipe.getOutputChance(tStartIndex)));
- }
- tStartInde