of

@Contract(value = "_, _, _ -> new", pure = true)
fun of(type: AttributeType, slot: EquipmentSlot, uuid: UUID, name: String, amount: Double, operation: BasicModifierOperation): ItemAttributeModifier

Creates a new item attribute modifier with the given type, slot, uuid, name, amount, operation.

Return

a new item attribute

Parameters

type

the type of the attribute

slot

the equipment slot

uuid

the UUID of the modifier

name

the name of the modifier

amount

the modifier amount

operation

the modifier operation


Creates a new item attribute modifier with the given type, slot, and modifier.

Return

the resulting item attribute modifier

Parameters

type

the type of the attribute

slot

the equipment slot

modifier

the modifier to take properties from

Throws

if the operation of the modifier is not a BasicModifierOperation.