Fixed when shift clicking crafting recipe and inventory is full items are dropping on the ground instead of going in the system, fixes #439

This commit is contained in:
Raoul Van den Berge
2016-10-12 16:12:53 +02:00
parent 9b4a5b3ece
commit 6807e780c2
2 changed files with 7 additions and 3 deletions

View File

@@ -19,6 +19,7 @@
- Fixed Storage Drawer quantities not updating properly on Void Drawers (geldorn)
- Fixed Disk Manipulator blocking items transferring in some cases (InusualZ)
- Fixed External Storage crafting recipe not supporting ore dictionary chests (raoulvdberge)
- Fixed when shift clicking crafting recipe and inventory is full items are dropping on the ground instead of going in the system (raoulvdberge)
- Updated Storage Drawers API (raoulvdberge)
### 1.1.3

View File

@@ -3,7 +3,10 @@ package refinedstorage.tile.grid;
import net.minecraft.client.Minecraft;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.inventory.*;
import net.minecraft.inventory.Container;
import net.minecraft.inventory.IInventory;
import net.minecraft.inventory.InventoryCraftResult;
import net.minecraft.inventory.InventoryCrafting;
import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.CraftingManager;
import net.minecraft.nbt.NBTTagCompound;
@@ -254,7 +257,7 @@ public class TileGrid extends TileNode implements IGrid {
if (i < remainder.length && remainder[i] != null) {
if (slot != null && slot.stackSize > 1) {
if (!player.inventory.addItemStackToInventory(remainder[i].copy())) {
InventoryHelper.spawnItemStack(player.worldObj, player.getPosition().getX(), player.getPosition().getY(), player.getPosition().getZ(), remainder[i].copy());
network.insertItem(remainder[i].copy(), remainder[i].stackSize, false);
}
matrix.decrStackSize(i, 1);
@@ -294,7 +297,7 @@ public class TileGrid extends TileNode implements IGrid {
for (ItemStack craftedItem : craftedItemsList) {
if (!player.inventory.addItemStackToInventory(craftedItem.copy())) {
InventoryHelper.spawnItemStack(player.worldObj, player.getPosition().getX(), player.getPosition().getY(), player.getPosition().getZ(), craftedItem);
network.insertItem(craftedItem, craftedItem.stackSize, false);
}
}