mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-03 23:07:40 +01:00
Merge branch 'master' of github.com:Bukkit/Bukkit
By: Dinnerbone <dinnerbone@dinnerbone.com>
This commit is contained in:
commit
b0bab301fe
@ -3,6 +3,16 @@ Bukkit
|
||||
|
||||
A Minecraft Server API.
|
||||
|
||||
Coding Conventions
|
||||
-----------
|
||||
|
||||
* We generally follow the Sun/Oracle coding standards.
|
||||
* No tabs; use 4 spaces instead.
|
||||
* No trailing whitespaces.
|
||||
* No 80 column limit or midstatement newlines.
|
||||
|
||||
Follow the above conventions if you want your pull requests accepted.
|
||||
|
||||
Compilation
|
||||
-----------
|
||||
|
||||
|
@ -98,6 +98,32 @@ public interface Inventory {
|
||||
*/
|
||||
public boolean contains(ItemStack item);
|
||||
|
||||
/**
|
||||
* Check if the inventory contains any ItemStacks with the given materialId and at least the minimum amount specified
|
||||
*
|
||||
* @param materialId The materialId to check for
|
||||
* @param amount The minimum amount to look for
|
||||
* @return If any ItemStacks were found
|
||||
*/
|
||||
public boolean contains(int materialId, int amount);
|
||||
|
||||
/**
|
||||
* Check if the inventory contains any ItemStacks with the given material and at least the minimum amount specified
|
||||
*
|
||||
* @param material The material to check for
|
||||
* @return If any ItemStacks were found
|
||||
*/
|
||||
public boolean contains(Material material, int amount);
|
||||
|
||||
/**
|
||||
* Check if the inventory contains any ItemStacks matching the given ItemStack and at least the minimum amount specified
|
||||
* This will only match if both the type and the amount of the stack match
|
||||
*
|
||||
* @param item The ItemStack to match against
|
||||
* @return If any matching ItemStacks were found
|
||||
*/
|
||||
public boolean contains(ItemStack item, int amount);
|
||||
|
||||
/**
|
||||
* Find all slots in the inventory containing any ItemStacks with the given materialId
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user