Container
Importing the class
If you need to reference this type directly, like when casting an Array, or as a parameter, you will need to import it. Simply add the import at the top of the file.
Implements
Container
implements the following interfaces:
Members
Getter
changed()
clearContent()
Clears the contents of this Clearable.
Getter
Gets the size (how many slots) of this Container
Return Type:
int
containerSize() as int
Gets the size (how many slots) of this Container
Returns: The amount of slots this Container has.
Return Type:
int
countItem(item as Item) as int
Parameters:
item: ItemDefinition
Type: ItemDefinition
Return Type:
int
countStack(item as IItemStack) as int
Parameters:
item: IItemStack
Type: IItemStack
Return Type:
int
getItem(index as int) as ItemStack
Gets the ItemStack in the given slot.
Returns: the ItemStack in the given slot.
Parameters:
index: int
Type: int
- The slot index to get.
Return Type:
ItemStack
hasAnyOf(items as Set<Item>) as bool
Parameters:
items: Set<ItemDefinition>
Type: Set<ItemDefinition>
Return Type:
bool
Getter
Checks if this Container is empty.
Return Type:
bool
isEmpty() as bool
Checks if this Container is empty.
Returns: True if empty. False otherwise.
Return Type:
bool
Getter
Return Type:
int
maxStackSize() as int
Return Type:
int
removeItem(var1 as int, var2 as int) as ItemStack
Parameters:
var1: int
Type: int
var2: int
Type: int
Return Type:
ItemStack
removeItemNoUpdate(index as int) as ItemStack
Parameters:
index: int
Type: int
Return Type:
ItemStack