ItemStack

Methods
5
Fields
None

Getting one

ItemStack.new(…)

Methods

MethodReturnsDescription
getId()numberThe item id.
getQuantity()numberThe quantity.
toString()stringItemStack(id=…, quantity=…).
equals(any)booleanWhether other equals this ItemStack, as == answers it (false for a value of another class).
new(number, number)ItemStackItemStack.new(id, quantity).

Returned by

MethodReturnsDescription
ItemStackClass.newItemStackItemStack.new(id, quantity).
LootManager.getItemSpawns{ItemStack}The stacks that spawned at worldPoint this tick, in spawn order.
PlayerLootReceived.getItems{ItemStack}The stacks, in spawn order.
ServerNpcLoot.getItems{ItemStack}The stacks.

Method details

equals

equals: (ItemStack, any) -> boolean

Whether other equals this ItemStack, as == answers it (false for a value of another class).

new

new: (number, number) -> ItemStack

ItemStack.new(id, quantity).