Private Villagers
ModMIT

Private Villagers

Makes villager trading by using allow lists and listening for workstation placement.

69
Downloads
1
Followers
3 months ago
Updated
📦
1
Versions

📖About Private Villagers

Private Villager

Server-side Fabric mod that makes villagers private! Only the player who placed a workstation can trade with the villager that claimed it. That player can then add allow more players to trade with their Villager!


🎯 How It Works

  1. You place a workstation (lectern, smithing table, etc.)
  2. A villager claims that workstation and gets a profession
  3. That villager now belongs to you — only you can trade with them
  4. Other players see: "You are not allowed to trade with this villager."

No client mod required — works entirely server-side!


✨ Features

Automatic Ownership

  • Villagers are automatically assigned to the player who placed their workstation
  • Ownership persists through server restarts
  • Works with all 13+ villager professions

Allow List System

  • Share your villagers with trusted players
  • Add or remove players from each villager's allow list
  • Allowed players can trade just like the owner

Admin Commands

  • Operators can reassign or clear villager ownership
  • Useful for server management and disputes

📋 Commands

All commands target the villager you're looking at, or optionally specify one with an entity selector.

Command Description Permission
/villager info [entity] Show owner and allow list Everyone
/villager add <player> [entity] Add player to allow list Owner only
/villager remove <player> [entity] Remove from allow list Owner only
/villager set <player> [entity] Set new owner OP only
/villager clear [entity] Remove all ownership data OP only

Tab completion is fully supported for player names and entity selectors.


🔧 Tracked Workstations

The mod tracks all villager job site blocks:

Block Profession
Blast Furnace Armorer
Smoker Butcher
Cartography Table Cartographer
Brewing Stand Cleric
Composter Farmer
Barrel Fisherman
Fletching Table Fletcher
Cauldron Leatherworker
Lectern Librarian
Stonecutter Mason
Loom Shepherd
Smithing Table Toolsmith
Grindstone Weaponsmith

📦 Installation

  1. Install Fabric Loader for your Minecraft version
  2. Install Fabric API
  3. Drop privatevillager-x.x.x-fabric.1.21.x.jar into your server's mods/ folder
  4. Restart the server

No client installation needed! Players connect with vanilla clients.


🎮 Compatibility

  • Minecraft: 1.21.8 – 1.21.11
  • Environment: Server-side only
  • Dependencies: Fabric API

💡 Use Cases

  • SMP Servers: Prevent villager theft and trading hall griefing
  • Economy Servers: Players can build and protect their own trading infrastructure
  • Shared Bases: Use the allow list to share villagers with teammates

📜 License

MIT License — free to use, modify, and redistribute.

♥️ Donate

If you would like to support me, you can donate here!