mirror of
https://github.com/songoda/EpicHoppers.git
synced 2024-11-22 18:25:59 +01:00
Hacky fix for disappearing items because of AutoCrafter
Should only be temporarily. Check if a slot is free or would be free after removing used ingredients and only then apply changes to the array
This commit is contained in:
parent
b6926b931f
commit
96076eb0e4
@ -63,7 +63,12 @@ public class ModuleAutoCrafting extends Module {
|
||||
}
|
||||
|
||||
synchronized (hopperCache) { //TODO: Check if this is required
|
||||
ItemStack[] items = hopperCache.cachedInventory;
|
||||
ItemStack[] items = new ItemStack[hopperCache.cachedInventory.length];
|
||||
|
||||
// TODO: Don't use that hacky workaround. Just don't modify it, if not meant to
|
||||
for (int i = 0; i < hopperCache.cachedInventory.length; i++) {
|
||||
items[i] = hopperCache.cachedInventory[i].clone();
|
||||
}
|
||||
|
||||
for (SimpleRecipe recipe : getRecipes(toCraft).recipes) {
|
||||
// key=indexForItemsArray, value=amountAfterCrafting
|
||||
|
Loading…
Reference in New Issue
Block a user