Skip to content
Browse files

Use the InventoryUtil method to add to an inventory. Supports fancy s…

…tuff like fuels for furnaces.
  • Loading branch information...
me4502 committed Oct 21, 2016
1 parent f26fea4 commit 1697d5b69761b9b1f77dae1a9b43c43fa08a4ab7
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/main/java/com/sk89q/craftbook/util/
@@ -387,7 +387,7 @@ public static void collectItem(AbstractIC ic, Vector offset, ItemStack... items)
Block invHolder = backB.getRelative(offset.getBlockX(), offset.getBlockY(), offset.getBlockZ());
if (InventoryUtil.doesBlockHaveInventory(invHolder)) {
InventoryHolder c = (InventoryHolder) invHolder.getState();
results = c.getInventory().addItem(results.toArray(new ItemStack[results.size()])).values();
results = InventoryUtil.addItemsToInventory(c, results.toArray(new ItemStack[0]));

// Drop whatever results were not added to the chest

0 comments on commit 1697d5b

Please sign in to comment.
You can’t perform that action at this time.