Fixed issue with autocrafting and named items.

This commit is contained in:
Brianna 2019-11-16 13:21:15 -05:00
parent 9c4fdd0971
commit e5f645ba6b

View File

@ -66,7 +66,9 @@ public class ModuleAutoCrafting extends Module {
for (ItemStack item : recipe.recipe) {
int amountHave = 0;
for (ItemStack hopperItem : hopperCache.cachedInventory) {
if (hopperItem != null && Methods.isSimilarMaterial(hopperItem, item))
if (hopperItem != null
&& !(hopperItem.hasItemMeta() && hopperItem.getItemMeta().hasDisplayName())
&& Methods.isSimilarMaterial(hopperItem, item))
amountHave += hopperItem.getAmount();
}
if (amountHave < item.getAmount()) {