Private Chest: Iron Keys

An iron chest that only you and your friends can open, with lendable keys, hopper control and rust for abandoned ones.

Your chest, your rules. Private Chest adds an iron chest that belongs to the player who places it. Nobody else opens it or breaks it unless you allow it.

Install it on both the server and every client. Requires Fabric Loader and Fabric API.

Crafting

  • Personal Chest: 8 iron ingots around a chest.
  • Iron Key: 1 iron ingot on top of 2 iron nuggets, in a vertical line.

Protection

  • Only the owner can open it, plus the players the owner allows.
  • By default, other players cannot break it and explosions cannot destroy it.
  • Whitelist (only listed players open) or blacklist (listed players cannot).
  • Add players even if they are offline or have never joined. On offline-mode servers, type the name with the exact capital letters.
  • Choose what hoppers may do: nothing (default), insert only, extract only, or both. Note: when extraction is allowed, any hopper can take items.
  • Give a chest to another player.
  • Two chests of the same owner placed side by side join into a large chest (hold Shift to keep them separate).

Keys

Put Iron Keys in the key slot of your chest to turn them into Assigned Keys. Whoever holds one in their main hand can open that chest, even without being on the list. A key has 1 use by default, then it breaks. It does not allow breaking the chest, and it stops working if the chest is broken or changes owner.

Rust

Abandoned chests rust. If the owner does not open a chest for 14 days (real time, by default), it turns rusty and loses its protections until the owner restores it with an axe. A broken rusted chest drops a Rusted Personal Chest, which can be cleaned on a grindstone. Rust can be turned off in the configuration.

Extras

  • 13 advancements and 16 statistics, usable in quest mods.
  • Optional "peek" mode: players without access can look inside without touching anything (off by default).
  • Optional log of who opened your chest (off by default).
  • Limit how many chests each player can own (unlimited by default).
  • Languages: English and Italian.

Commands

/pc is short for /privatechest.

  • /pc list shows your chests.
  • /pc info shows the chest you are looking at.
  • /pc transfer <name> gives that chest to another player.
  • /pc all add <name>, /pc all remove <name>, /pc all mode <whitelist|blacklist>, /pc all clear change all your chests at once.
  • /pc admin reload reloads the configuration (operators).

Configuration

The file config/private_chest.json is created the first time a world starts, with a comment for every setting. On a server, only the server's file matters.

Operators can open and break protected chests by default. Both can be turned off.

Known limits

  • Commands such as /setblock, /fill and /clone are not blocked. A cloned chest keeps its owner and its lock.
  • Mods that remove blocks without going through Fabric's events are not stopped.
  • Openings made with a key do not appear in the opening log.

Found a bug?

Back up your world before installing or updating. To report a problem, write a comment with what you were doing, the chest coordinates and your logs/latest.log (share it through a paste site).


Chest textures are recolored from Minecraft's Copper Chest textures. Not an official Minecraft product. Not approved by or associated with Mojang or Microsoft.

Private Chest: Iron Keys Team

profile avatar
Owner
  • 2
    Followers
  • 2
    Projects
  • 2.1K
    Downloads

More from Jaco_29