From 11a31e7bcd0d4fdda98a68c9face6f9372c23936 Mon Sep 17 00:00:00 2001 From: mezz Date: Sat, 27 Feb 2016 00:51:39 -0800 Subject: [PATCH] Fix #359 JEI Alloy Smelter is not showing stack amount required --- .../java/techreborn/compat/jei/BaseRecipeWrapper.java | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/main/java/techreborn/compat/jei/BaseRecipeWrapper.java b/src/main/java/techreborn/compat/jei/BaseRecipeWrapper.java index 9d530c483..16e133645 100644 --- a/src/main/java/techreborn/compat/jei/BaseRecipeWrapper.java +++ b/src/main/java/techreborn/compat/jei/BaseRecipeWrapper.java @@ -42,7 +42,15 @@ public abstract class BaseRecipeWrapper extends BlankRecip for (int oreId : oreIds) { String oreName = OreDictionary.getOreName(oreId); List ores = OreDictionary.getOres(oreName); - itemStackSet.addAll(ores); + for (ItemStack ore : ores) { + if (ore.stackSize != itemStack.stackSize) { + ItemStack oreCopy = ore.copy(); + oreCopy.stackSize = itemStack.stackSize; + itemStackSet.add(oreCopy); + } else { + itemStackSet.add(ore); + } + } } return new ArrayList<>(itemStackSet); }