Back to 9Minecraft
Wiki 9Minecraft Wiki 9Minecraft
Villager Api Wiki › Guides › Add Treasure Maps and Raid Gifts to Villager Trades

Add Treasure Maps and Raid Gifts to Villager Trades

Including Treasure Maps in Trades

You can make villagers sell treasure maps that point to custom structures or vanilla Minecraft locations like temples and mansions. In your trade configuration, add treasure map items to a high-level villager's trade list (typically Expert or Master level).

Specify the map destination—either a custom structure you've defined elsewhere in your mod setup, or a standard Minecraft structure type.

Customizing Raid Gift Drops

When players defeat a raid near a villager, that villager throws gifts as a reward. By default these are common items, but you can customize them. In your profession or trade file, define a "raid gifts" section listing items the villager should throw.

You can include:

  • Rare materials
  • Enchanted items
  • Custom potions
  • Renamed or special items

Testing

Trigger a raid near your custom villager and defeat it to see your configured gifts drop. Adjust your gift list in the config file and reload to test different rewards.