From c72a7064d858d2c43558f3011d75d4f2ea53e4f3 Mon Sep 17 00:00:00 2001
From: Bukkit/Spigot <noreply+git-bukkit@papermc.io>
Date: Sun, 16 Jan 2011 16:10:22 +0100
Subject: [PATCH] Added Invenrory.removeItem(ItemStack...)

By: Erik Broes <erikbroes@grum.nl>
---
 .../java/org/bukkit/inventory/Inventory.java     | 16 +++++++++++++++-
 1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/paper-api/src/main/java/org/bukkit/inventory/Inventory.java b/paper-api/src/main/java/org/bukkit/inventory/Inventory.java
index b05acf9642..e4bc9afd59 100644
--- a/paper-api/src/main/java/org/bukkit/inventory/Inventory.java
+++ b/paper-api/src/main/java/org/bukkit/inventory/Inventory.java
@@ -38,13 +38,27 @@ public interface Inventory {
      public void setItem(int index, ItemStack item);
 
     /**
-     * Stores the given ItemStacks in the inventory 
+     * Stores the given ItemStacks in the inventory.
+     * 
+     * This will try to fill existing stacks and empty slots as good as it can.
+     * It will return a HashMap of what it couldn't fit.
      * 
      * @param items The ItemStacks to add
      * @return 
      */
      public HashMap<Integer, ItemStack> addItem(ItemStack... items);
 
+    /**
+     * Removes the given ItemStacks from the inventory.
+     * 
+     * It will try to remove 'as much as possible' from the types and amounts you
+     * give as arguments. It will return a HashMap of what it couldn't remove.
+     * 
+     * @param items The ItemStacks to remove
+     * @return 
+     */
+     public HashMap<Integer, ItemStack> removeItem(ItemStack... items);
+
     /**
      * Get all ItemStacks from the inventory
      *