ItemAttributeModifierHelper
com.jsmacrosce.jsmacros.client.api.helper.inventory.ItemAttributeModifierHelper
Describes one configured item attribute modifier and where it applies.
js
const modifiers = Player.getPlayer()?.getMainHand().getComponents().getAttributeModifiers();
if (modifiers != null) {
for (const modifier of modifiers) {
Chat.log(`${modifier.getAttributeId()}: ${modifier.getOperation()} ${modifier.getAmount()}`);
}
}Methods
getAmount
getAmount(): double#Returns: the modifier amount, interpreted according to its operation