Wiki 9Minecraft Custom Villager Trades Wiki
Custom Villager Trades Wiki › Configuration

Custom Villager Trades — Configuration

Item Options

The item a trade gives out does not have to be a plain stack. Each item entry can be dressed up so the reward feels special:

  • Custom name — rename the item, so a trade can sell a sword called "Villager's Bane" or a star called "Fallen Star".
  • Enchantments — add one or more enchantments at chosen levels. You can pin an exact level, pick a random level within a range, or let the game roll a random enchantment for you. Enchantments work on tools, armour and weapons, and are stored correctly on enchanted books.
  • Random enchantments with a blacklist — ask for a random enchantment but exclude ones you do not want, so a trade never rolls something useless.
  • Potion effects — turn a potion, tipped arrow or similar item into one carrying the effects you list, at the duration and strength you choose, with an optional custom colour.
  • Extra data — attach custom item data for items that need it, and point map items at a structure so they generate as explorer maps.

These options apply to the reward and to the payment items alike, so you can even require an enchanted or specifically named item as the price.

Commands

Two commands make editing trades convenient while a world is running:

  • Reload — re-reads the configuration files without restarting the game, so you can tweak a trade and see the result on newly created villagers straight away.
  • Export — writes the currently loaded trades back out to an exports folder, which is a quick way to capture a working set of trades or to produce a template you can copy from.

Both commands are limited to operators by default, and the permission level required can be changed in the global configuration.

Global Configuration

Alongside the per-profession files there is a single global configuration file for settings that apply to the mod as a whole, such as the operator permission level needed to use the commands.

Any mistakes in a trade file — an item id that does not exist, or an enchantment that cannot be applied to the chosen item — are reported when the configuration loads and again to operators when they join, so a broken trade is easy to find and fix rather than silently disappearing.