public interface IAEStack<T extends IAEStack<T>>
| Modifier and Type | Method and Description |
|---|---|
void |
add(T is)
add two stacks together
|
net.minecraft.item.ItemStack |
asItemStackRepresentation()
Returns itemstack for display and similar purposes.
|
T |
copy()
Clone the Item / Fluid Stack
|
void |
decCountRequestable(long i)
removes items from the requestable
|
void |
decStackSize(long i)
removes some from the stack size.
|
T |
empty()
create an empty stack.
|
boolean |
equals(java.lang.Object obj)
Compare stacks using precise logic.
|
boolean |
fuzzyComparison(T other,
FuzzyMode mode)
Compare the same subtype of
IAEStack with another using a fuzzy comparison. |
IStorageChannel<T> |
getChannel() |
long |
getCountRequestable()
Same as getStackSize, but for requestable items. ( LP )
|
long |
getStackSize()
number of items in the stack.
|
void |
incCountRequestable(long i)
adds items to the requestable
|
void |
incStackSize(long i)
Adds more to the stack size...
|
boolean |
isCraftable()
true, if the item can be crafted.
|
boolean |
isFluid() |
boolean |
isItem() |
boolean |
isMeaningful()
returns true, if the item can be crafted, requested, or extracted.
|
T |
reset()
clears, requestable, craftable, and stack sizes.
|
T |
setCountRequestable(long countRequestable)
Same as setStackSize, but for requestable items. ( LP )
|
T |
setCraftable(boolean isCraftable)
change weather the item can be crafted.
|
T |
setStackSize(long stackSize)
changes the number of items in the stack.
|
void |
writeToNBT(net.minecraft.nbt.NBTTagCompound i)
write to a NBTTagCompound.
|
void |
writeToPacket(io.netty.buffer.ByteBuf data)
Slower for disk saving, but smaller/more efficient for packets.
|
void add(T is)
is - added itemlong getStackSize()
T setStackSize(long stackSize)
stackSize - , ItemStack.stackSize = Nlong getCountRequestable()
T setCountRequestable(long countRequestable)
boolean isCraftable()
T setCraftable(boolean isCraftable)
isCraftable - can item be craftedT reset()
boolean isMeaningful()
void incStackSize(long i)
i - additional stack sizevoid decStackSize(long i)
void incCountRequestable(long i)
i - increased amount of requested itemsvoid decCountRequestable(long i)
i - decreased amount of requested itemsvoid writeToNBT(net.minecraft.nbt.NBTTagCompound i)
i - to be written databoolean equals(java.lang.Object obj)
equals in class java.lang.Objectobj - compared objectboolean fuzzyComparison(T other, FuzzyMode mode)
IAEStack with another using a fuzzy comparison.other - The stack to compare.mode - Which FuzzyMode should be used.void writeToPacket(io.netty.buffer.ByteBuf data)
throws java.io.IOException
data - to be written datajava.io.IOExceptionT copy()
T empty()
boolean isItem()
IAEItemStackboolean isFluid()
IAEFluidStackIStorageChannel<T> getChannel()
net.minecraft.item.ItemStack asItemStackRepresentation()