aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/gregtech/api
diff options
context:
space:
mode:
authorBlood-Asp <bloodasphendrik@gmail.com>2016-01-03 16:49:00 +0100
committerBlood-Asp <bloodasphendrik@gmail.com>2016-01-03 16:49:00 +0100
commit874dfdc3097010b3aaa09266e45ba61fecbbb868 (patch)
tree2c59cf81a1d86e10c883f0c10e81cde642b2fcb6 /src/main/java/gregtech/api
parent5fd2db9ef23d3348810e658ab0641f842e854fdb (diff)
downloadGT5-Unofficial-874dfdc3097010b3aaa09266e45ba61fecbbb868.tar.gz
GT5-Unofficial-874dfdc3097010b3aaa09266e45ba61fecbbb868.tar.bz2
GT5-Unofficial-874dfdc3097010b3aaa09266e45ba61fecbbb868.zip
Fix forestry worktable crash
Diffstat (limited to 'src/main/java/gregtech/api')
-rw-r--r--src/main/java/gregtech/api/util/GT_Shaped_Recipe.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/gregtech/api/util/GT_Shaped_Recipe.java b/src/main/java/gregtech/api/util/GT_Shaped_Recipe.java
index fe78d6a854..e51c490519 100644
--- a/src/main/java/gregtech/api/util/GT_Shaped_Recipe.java
+++ b/src/main/java/gregtech/api/util/GT_Shaped_Recipe.java
@@ -73,8 +73,9 @@ public class GT_Shaped_Recipe extends ShapedOreRecipe implements IGT_CraftingRec
ItemStack tStack = aGrid.getStackInSlot(i);
if (tStack != null && GT_Utility.getContainerItem(tStack, true) == null && !(tStack.getItem() instanceof GT_MetaGenerated_Tool)) {
tStack = GT_Utility.copyAmount(1, tStack);
+ if(GT_Utility.isStackValid(tStack)){
GT_ModHandler.dischargeElectricItem(tStack, Integer.MAX_VALUE, Integer.MAX_VALUE, true, false, true);
- tNBT.setTag("Ingredient." + i, tStack.writeToNBT(new NBTTagCompound()));
+ tNBT.setTag("Ingredient." + i, tStack.writeToNBT(new NBTTagCompound()));}
}
}
rNBT.setTag("GT.CraftingComponents", tNBT);