Hi, I am having a bit of a struggle with replacing loot in LootJS.
This is what the log says:
[12:15:34] [ERROR] ! lootJS.js#9: Error in 'LootJS.modifiers': dev.latvian.mods.rhino.EvaluatorException: Can't find method com.almostreliable.lootjs.core.filters.ItemFilter.item(string).
This is what I did:
event.addTableModifier(LootType.CHEST).replaceLoot(ItemFilter.item("minecraft:iron_ingot"), "minecraft:iron_nugget")
Am I using it wrong?
For reference:
This is the Filter example from the documentation:
ItemFilter.item("minecraft:diamond")
This is the example from the wiki on how to replace:
event.addTableModifier("minecraft:chests/simple_dungeon").replaceLoot(ItemFilter.equipmentSlot("mainhand"), "minecraft:diamond")