Examples of addWithLeftovers()


Examples of net.aufdemrand.denizen.objects.dInventory.addWithLeftovers()

                    }
                    if (set_quantity)
                        is.setAmount(qty.asInt());
                    if (engrave.asBoolean()) is = CustomNBT.addCustomNBT(item.getItemStack(), "owner", ((BukkitScriptEntryData)scriptEntry.entryData).getPlayer().getName());

                    List<ItemStack> leftovers = inventory.addWithLeftovers(slot.asInt()-1, limited, is);

                    if (!leftovers.isEmpty()) {
                        dB.echoDebug (scriptEntry, "The inventory didn't have enough space, the rest of the items have been placed on the floor.");
                        for (ItemStack leftoverItem : leftovers)
                            inventory.getLocation().getWorld().dropItem(inventory.getLocation(), leftoverItem);
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.