Fix spell cloth duplication glitch #2810

This commit is contained in:
Vincent Lee committed 2018-12-25 22:23:16 -06:00
1 parent 43734ee338
commit daff8ece87
1 file changed
+2 -4
@@ -56,6 +56,7 @@ public class SpellClothRecipe extends IForgeRegistryEntry.Impl<IRecipe> implemen
ItemStack stack = var1.getStackInSlot(i);
if(!stack.isEmpty() && stack.isItemEnchanted()) {
stackToDisenchant = stack.copy();
stackToDisenchant.setCount(1);
break;
}
}
@@ -63,10 +64,7 @@ public class SpellClothRecipe extends IForgeRegistryEntry.Impl<IRecipe> implemen
if(stackToDisenchant.isEmpty())
return ItemStack.EMPTY;
NBTTagCompound cmp = stackToDisenchant.getTagCompound().copy();
cmp.removeTag("ench"); // Remove enchantments
stackToDisenchant.setTagCompound(cmp);
stackToDisenchant.getTagCompound().removeTag("ench"); // Remove enchantments
return stackToDisenchant;
}