Repository navigation
Fixing Problems
Read the Fixing Errors page of the Trigger Engine wiki. It teaches you to read every message. The main ideas are that every mistake is shown with its file and line and often a suggestion, and that the previous working version keeps being used when there are errors.
An enchantment file with a mistake in one of its options (name, levels, items, rarity...) is skipped: the enchantment will not exist until you fix it and restart.
My new enchantment does not exist.
New enchantments need a restart. /metaenchants reload tells you about new files but cannot add them to the game. Also check the console at startup for errors in the file.
I changed the max level (or weight, items, rarity...) and nothing changed. Those options need a restart. See Restart or reload?.
The enchantment does not appear in /enchant (or the Tab list).
Look at the start of the console for errors about the file. Use the full id, metaenchants:name.
The game says the item "cannot support that enchantment".
Either the item is not in supported-items, or the item already has an enchantment that is incompatible. Check /metaenchants info <enchantment>. See Items, Slots and Incompatibilities.
The enchantment is on the item, but its trigger does nothing. Check that:
- You ran
/metaenchants reloadafter editing, and the console said it loaded. - The item is in the right place. The enchantment only works for items in its
slots. A[mainhand]enchantment does nothing in the off hand. - The event is the right one:
attackwhen the player hits;defendwhen the player is hit. - The conditions are not too strict, and there is no
cooldownblocking it. Try a trigger with justonand amessageto see that it happens. - For an
activation: event-itemenchantment, the event must carry an item.
It works too well, or not enough, at high levels.
Everything that uses {level} scales with it, even above the maximum. See Levels Above the Maximum.
The enchantment never shows up in the enchanting table.
It may be a treasure enchantment, enchanting-table may be false, or its min-cost may be too high for the tables you test with. See Where Enchantments Appear.
The tooltip shows enchantment.level.11.
That is how the game shows levels above 10 without a translation. Turn on tooltip.enabled in config.yml. See Levels Above the Maximum.
Items show no descriptions.
Check tooltip.enabled and tooltip.descriptions.enabled in config.yml, that the item has no more enchantments than tooltip.descriptions.limit, and that the player did not hide them with /metaenchants descriptions. See Tooltips.
Clicking a book on an item swaps them instead of applying it.
Dragging books is off: check apply.drag-and-drop in config.yml and drag-and-drop in the enchantment file. It only works with left or right click, on items in the player's own inventory, and not in the creative inventory screen. See Applying Enchantments.
The anvil shows no result for an item it should accept.
The result would break a rule: a missing requires, the maximum enchantments per item, or the limit of a type. Dragging the book onto the item tells the player which one.
Books do not stack.
Only books of the same enchantment and level with stackable: true stack. With rates in a range like 60-100, each book has its own numbers and they do not stack: use a single value. Books created before the change keep their old settings.
The console says mentions enchantments that do not exist.
An id in requires or replaces is wrong. MetaEnchants enchantments can be written without metaenchants:; vanilla ones need minecraft:.
The console says 'x' is not an enchantment and is ignored for vanilla.yml.
The id in vanilla.yml is wrong. Use the ids of /enchant, like sharpness or fire_aspect.
An enchantment has no triggers but the console does not complain.
That is normal for enchantments that only use options, like soulbound.
The menu does not let me take books.
You need the permission metaenchants.menu.take. See Commands and Permissions.
The console says 'x' does not exist for an item or tag.
The name in supported-items, primary-items or incompatible is not valid. The message lists the ones it did not find. The tag #minecraft:enchantable/sword, for example, does not exist: use #minecraft:swords or #minecraft:enchantable/sharp_weapon.
Compare your file with the examples or with the included enchantments, and change one thing at a time.