Examples of onSlotChange()


Examples of net.minecraft.inventory.Slot.onSlotChange()

            if (par1 == 2)
            {
                if (!this.mergeItemStack(var4, 3, 39, true))
                    return null;
               
                var3.onSlotChange(var4, var2);
            }
            else if (par1 != 1 && par1 != 0)
            {
                if (var4.getItem() instanceof IItemElectric)
                {
View Full Code Here

Examples of net.minecraft.inventory.Slot.onSlotChange()

            if (par1 == 2)
            {
                if (!this.mergeItemStack(var4, 3, 39, true))
                    return null;
               
                var3.onSlotChange(var4, var2);
            }
            else if (par1 != 1 && par1 != 0)
            {
                if (var4.getItem() instanceof IItemElectric)
                {
View Full Code Here

Examples of net.minecraft.inventory.Slot.onSlotChange()

        }
      } else if (!shiftItemStack(stackInSlot, numSlots - 9 * 4, numSlots))
      {
        return null;
      }
      slot.onSlotChange(stackInSlot, originalStack);
      if (stackInSlot.stackSize <= 0)
      {
        slot.putStack(null);
      } else
      {
View Full Code Here

Examples of net.minecraft.inventory.Slot.onSlotChange()

      } else if(slotDef.isOutputSlot(slotIndex)) {
        // merge result
        if(!mergeItemStack(origStack, startPlayerSlot, endHotBarSlot, true)) {
          return null;
        }
        slot.onSlotChange(origStack, copystack);

      } else {
        //Check from inv->input then inv->upgrade then inv->hotbar or hotbar->inv
        if(slotIndex >= startPlayerSlot) {
          if(slotDef.getNumInputSlots() <= 0 || !mergeItemStack(origStack, slotDef.getMinInputSlot(), slotDef.getMaxInputSlot() + 1, false)) {
View Full Code Here

Examples of net.minecraft.inventory.Slot.onSlotChange()

                if (!this.mergeItemStack(itemstack1, 3, 39, true))
                {
                    return null;
                }

                slot.onSlotChange(itemstack1, itemstack);
            }
            else if (par2 != 1 && par2 != 0)
            {
                if (FurnaceRecipes.smelting().getSmeltingResult(itemstack1) != null)
                {
View Full Code Here

Examples of net.minecraft.inventory.Slot.onSlotChange()

                if (!this.mergeItemStack(itemstack1, 9+4, 45+4, true))
                {
                    return null;
                }

                slot.onSlotChange(itemstack1, itemstack);
            }
            else if (par2 >= 1 && par2 < 5)
            {
                if (!this.mergeItemStack(itemstack1, 9+4, 45+4, false))
                {
View Full Code Here

Examples of net.minecraft.inventory.Slot.onSlotChange()

                            return null;
                        }
                    }
                }

                slot.onSlotChange(itemStack, returnStack);
            } else if(slotPos >= boundaries.get(Boundaries.BACKPACK) && slotPos < boundaries.get(Boundaries.BACKPACK_END)) { // from backpack
                if(!mergeItemStack(itemStack, boundaries.get(Boundaries.HOTBAR), boundaries.get(Boundaries.HOTBAR_END), true)) { // to hotbar
                    if(!mergeItemStack(itemStack, boundaries.get(Boundaries.INVENTORY), boundaries.get(Boundaries.INVENTORY_END), false)) { // to inventory
                        return null;
                    }
View Full Code Here

Examples of net.minecraft.inventory.Slot.onSlotChange()

                if (!this.mergeItemStack(var5, 3, 39, true))
                {
                    return null;
                }

                var4.onSlotChange(var5, var3);
            }
            else if (par2 != 1 && par2 != 0)
            {
                if (ResearchRecipes.smelting().getSmeltingResult(var5) != null)
                {
View Full Code Here

Examples of net.minecraft.inventory.Slot.onSlotChange()

                    return null;
                }

                if (par1 == 6)
                {
                    slot.onSlotChange(var4, var2);
                }
            }
            else
            {
                Item i = var4.getItem();
View Full Code Here

Examples of net.minecraft.inventory.Slot.onSlotChange()

                    return null;
                }

                if (par1 == 0)
                {
                    slot.onSlotChange(var4, var2);
                }
            }
            else
            {
                Item i = var4.getItem();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.