Skip to content

适用于 Minecraft 1.21.1 的 Villager API 模组

一个无需编写代码即可添加自定义村民职业和村民生物群系类型以及自定义交易的 API。

次浏览
22 次浏览
已更新
已更新 18.10.2026

Villager API

A simple data-driven framework for making custom villager professions, types, and trades without touching any code. Just drop JSON files in a folder and you're done. You can also override or merge custom trades into vanilla or other modded villager's trades.

What does it do?

This mod lets you create completely custom villagers with your own:

  • Professions - New jobs with custom workstations and trading lists
  • Types - Different villager appearances tied to specific biomes
  • Trades - Full control over what villagers buy and sell at each level
  • Hero Gifts - Custom loot tables for post-raid rewards

Everything is handled through JSON files in the villagerpacks folder. No coding, no complex setup—just make your files and load up the game.

Quick Example

Want an Alchemist villager who uses a crying obsidian block as their workstation?

  • Create villagerpacks/my_pack/villagers/poi_types/alchemist.json and villagerpacks/my_pack/villagerapi_config.json
  • Define the workstation block
  • Add the profession file linking to that POI type
  • Set up your trades
  • Drop in textures for the profession overlay

That's it. The mod handles registration, trade mechanics, and everything else.

What can you customize?

  • Workstations - Any block can be a job site
  • Trading pools - Define exactly what villagers offer at each experience level (Novice through Master)
  • Item components - Full support for enchantments, custom names, potions, and all the data components Minecraft uses
  • Treasure maps - Sell maps to modded or vanilla structures with custom markers
  • Biome appearances - Make villagers look different depending on where they spawn
  • Biome-specific trades - Same profession, different inventory based on villager's biome type

Who and what is this for?

If you've ever wanted to add villagers to your modpack or mod without dealing with Java code, this is for you. It's built for pack makers and modders who want villager content without the headache of getting into learning and writing java code.

Works with both regular resource pack like villager packs and as part of mods by simply putting a villagers folder in your mods main directory. Multiple packs can run at once—later packs override earlier ones where there's overlap.

Full Documentation

Check the complete documentation with examples and all available options here: https://github.com/frikinjay/villagerapi/blob/main/DOCUMENTATION.md

You can generate a pack online here without having to manually create all the files: Villager Pack Generator

The docs include the full pack structure, all JSON formats, item component examples, and a complete example pack to get you started.

如何安装 Villager API

With Millida Launcher

  1. Install Millida Launcher

    The launcher is free: download it at millida.net/launcher and sign in with any nickname.

  2. Click “Install” on this page

    The launcher opens and installs the mod for Minecraft 1.21.1 on Fabric, NeoForge or Quilt automatically.

  3. Launch the game

    A profile with it appears in the launcher: click “Play”.

Manually

  1. Install Fabric, NeoForge or Quilt

    The loader must match the game version of the mod file, for example Minecraft 1.21.1. After installing it, a separate profile appears in your launcher.

  2. Download the file for your version

    In the version list above, pick the file Villager-API-1.21.1-neoforge-1.26.9.5.jar (158 KB) for your game version and loader.

  3. Put it in the mods folder

    The folder is inside .minecraft (Windows: %appdata%\.minecraft\mods). If it does not exist, create it.

  4. Launch the loader profile

    Open “Mods” in the main menu: Villager API should be in the list.

Minecraft 1.21.1 runs on Java 21: with a different Java version the game may close right after launch.

版本

含依赖项

Minecraft加载器文件日期操作
1.21.1NeoForgeVillager-API-1.21.1-neoforge-1.26.9.5.jar158 KB
1.21.1Fabric, QuiltVillager-API-1.21.1-fabric-1.26.9.5.jar156 KB

评价

成为第一个评价 Villager API 的人

评论 0

登录后即可评论登录

相似模组

全部模组

了解更多