Enchantment
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.
Members
Getter
Return Type:
int
canEnchant(stack as IItemStack) as bool
Parameters:
stack: IItemStack
Type: IItemStack
Return Type:
bool
Getter
Return Type:
string
Getter
Return Type:
EnchantmentDefinition
Getter
Return Type:
Component
Getter
Return Type:
Enchantment[]
getMaxCost(level as int) as int
Parameters:
level: int
Type: int
Return Type:
int
getMinCost(level as int) as int
Parameters:
level: int
Type: int
Return Type:
int
getSlotItems(entity as LivingEntity) as IItemStack[EquipmentSlot]
Parameters:
entity: LivingEntity
Type: LivingEntity
Return Type:
IItemStack[EquipmentSlot]
isPrimaryItem(stack as IItemStack) as bool
Parameters:
stack: IItemStack
Type: IItemStack
Return Type:
bool
isSupportedItem(stack as IItemStack) as bool
Parameters:
stack: IItemStack
Type: IItemStack
Return Type:
bool
matchingSlot(slot as EquipmentSlot) as bool
Parameters:
slot: EquipmentSlot
Type: EquipmentSlot
Return Type:
bool
Getter
Return Type:
int
Getter
Return Type:
int
Getter
Return Type:
ResourceLocation
Getter
Return Type:
ItemDefinition[]
Getter
Return Type:
int