Fix glow panel placement, fixed damage displays (again), start work on new inventory system

This commit is contained in:
aidancbrady committed 2017-03-28 23:21:06 -04:00
1 parent 2aad738c3d
commit fa7b9b49bc
14 files changed
+70 -27

No files matched your search

@@ -90,7 +90,7 @@ public final class InventoryUtils
ItemStack inSlot = inventory.getStackInSlot(i);
if(inSlot == null)
if(inSlot == null || inSlot.isEmpty())
{
if(toInsert.getCount() <= inventory.getInventoryStackLimit())
{
@@ -170,7 +170,7 @@ public final class InventoryUtils
ItemStack inSlot = inventory.getStackInSlot(slotID);
if(inSlot == null)
if(inSlot == null || inSlot.isEmpty())
{
if(toInsert.getCount() <= inventory.getInventoryStackLimit())
{
@@ -443,7 +443,7 @@ public final class InventoryUtils
ItemStack inSlot = inventory.getStackInSlot(i);
if(inSlot == null)
if(inSlot == null || inSlot.isEmpty())
{
if(itemStack.getCount() <= inventory.getInventoryStackLimit())
{
@@ -502,7 +502,7 @@ public final class InventoryUtils
ItemStack inSlot = inventory.getStackInSlot(slotID);
if(inSlot == null)
if(inSlot == null || inSlot.isEmpty())
{
if(itemStack.getCount() <= inventory.getInventoryStackLimit())
{
@@ -550,6 +550,7 @@ public final class InventoryUtils
/*TODO From CCLib -- go back to that version when we're using dependencies again*/
public static boolean canStack(ItemStack stack1, ItemStack stack2) {
return stack1 == null || stack2 == null ||
stack1.isEmpty() || stack2.isEmpty() ||
(stack1.getItem() == stack2.getItem() &&
(!stack2.getHasSubtypes() || stack2.getItemDamage() == stack1.getItemDamage()) &&
ItemStack.areItemStackTagsEqual(stack2, stack1)) &&