From 8f65aad67b5a3410f1609a3a8e46fa6df1b35cd8 Mon Sep 17 00:00:00 2001 From: AlgorithmX2 Date: Sat, 12 Jul 2014 17:14:28 -0500 Subject: [PATCH] Fixed MA Crash with processing Patterns. --- tile/crafting/TileMolecularAssembler.java | 13 ++++++++----- util/item/AEItemStack.java | 2 +- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/tile/crafting/TileMolecularAssembler.java b/tile/crafting/TileMolecularAssembler.java index 9db92a259..db338bbae 100644 --- a/tile/crafting/TileMolecularAssembler.java +++ b/tile/crafting/TileMolecularAssembler.java @@ -85,7 +85,7 @@ public class TileMolecularAssembler extends AENetworkInvTile implements IAEAppEn for (int x = 0; x < inv.getSizeInventory(); x++) isEmpty = inv.getStackInSlot( x ) == null && isEmpty; - if ( isEmpty ) + if ( isEmpty && patternDetails.isCraftable() ) { forcePlan = true; myPlan = patternDetails; @@ -119,9 +119,12 @@ public class TileMolecularAssembler extends AENetworkInvTile implements IAEAppEn ItemEncodedPattern iep = (ItemEncodedPattern) is.getItem(); ICraftingPatternDetails ph = iep.getPatternForItem( is, w ); - progress = 0; - myPattern = is; - myPlan = ph; + if ( ph.isCraftable() ) + { + progress = 0; + myPattern = is; + myPlan = ph; + } } } else @@ -223,7 +226,7 @@ public class TileMolecularAssembler extends AENetworkInvTile implements IAEAppEn World w = getWorldObj(); ItemEncodedPattern iep = (ItemEncodedPattern) myPat.getItem(); ICraftingPatternDetails ph = iep.getPatternForItem( myPat, w ); - if ( ph != null ) + if ( ph != null && ph.isCraftable() ) { forcePlan = true; myPlan = ph; diff --git a/util/item/AEItemStack.java b/util/item/AEItemStack.java index d1750f075..5eabfb8c4 100644 --- a/util/item/AEItemStack.java +++ b/util/item/AEItemStack.java @@ -113,7 +113,7 @@ public final class AEItemStack extends AEStack implements IAEItemS { if ( ia instanceof AEItemStack ) { - return ((AEItemStack) ia).def.equals( def ) && def.tagCompound == ((AEItemStack) ia).def.tagCompound; + return ((AEItemStack) ia).def.equals( def );// && def.tagCompound == ((AEItemStack) ia).def.tagCompound; } else if ( ia instanceof ItemStack ) {