ChestShare
简介
为每位玩家提供独立的世界生成宝箱 loot —— 100% 服务端运行。甚至能恢复在你安装此模组之前已被搜刮过的宝箱。
描述
每位玩家都能获得地牢宝箱的 loot,而不仅仅是第一个发现者。
在生存服务器上,第一个找到结构建筑的玩家会将其搜刮一空。后续进入的玩家探索的是一个已经被洗劫的世界。ChestShare 为每位玩家提供每个世界生成容器的独立实例——相同的种子、相同的 loot,不会有人被遗漏。
并且它是 100% 服务端运行:只需将一个 jar 文件放入 mods/ 目录即可。无需客户端安装,兼容原版客户端、启动器锁定的整合包玩家以及破解版整合包玩家。
功能特性
- 每位玩家的独立 loot 实例——箱子、陷阱箱、桶、潜影盒、发射器、箱子矿车,以及基于原版机制构建的模组容器。两名玩家打开同一个地牢宝箱时,看到的物品完全相同,但各自拥有独立的副本。
- 支持存取——玩家可以取出 和 存放物品到他们的实例中;所有内容都会随世界持久化保存。
- 包含模组生成的结构——在区块生成时捕获容器,无论它们使用 loot 表还是预先填充了自定义模组物品(完整的 NBT 数据)。
- 无漏洞利用——漏斗和管道无法触碰共享容器;破坏其中一个只会掉落破坏者自己的实例;玩家放置的箱子始终保持原版行为。
- 双联箱处理得当——合并后的 54 格界面,每半部分分别追踪管理。
安装太晚怎么办?我们也遇到过。
ChestShare 诞生于一个活跃的 Cobblemon (COBBLEVERSE) 服务器,那里的玩家已经探索并清空了整个地图上的宝箱。原版会在宝箱被打开的瞬间删除其 loot 表——这些信息从世界中永远消失。
但世界生成是确定性的。因此 ChestShare 提供了一个 恢复工作流:
- 复制你的服务器设置(相同的模组、相同的种子),删除世界副本。
- 在该镜像上预生成已探索的区域(Chunky 效果很好)——ChestShare 会在生成过程中捕获每一个容器。
- 在镜像服务器上执行
/chestshare export recovery。
- 在你的真实服务器上执行
/chestshare import recovery:所有仍然存在的宝箱——包括那些已经被搜刮过的——都变成带有原始 loot 的共享容器。
导入操作分布在多个服务器刻内完成(无卡顿,不会被 watchdog 杀死),默认跳过非空容器以避免占用玩家存储空间。在我们的服务器上:从镜像导出了 332 个容器,一条命令恢复了 241 个,除了重启外零停机时间。
指令(权限等级 2)
| 指令 |
效果 |
/chestshare convert <pos> <loot_table> |
将单个容器(例如模组安装前被搜刮过的箱子)转换为共享容器 |
/chestshare reset <pos> |
清除玩家实例——为所有人重新生成 loot |
/chestshare export <file> |
将所有已捕获的容器导出到文件 |
/chestshare import <file> [force] |
将导出应用到当前世界(恢复用) |
须知
- Fabric,Minecraft 1.21.1,Java 21。需要 Fabric API。仅服务端(也适用于单人/LAN)。
- 安装前生成的区块:未打开的容器在首次打开时仍会自动转换(其 loot 表完好无损);已被搜刮过的容器需要上述恢复工作流。
- 完全自定义的容器实现(不基于原版 loot 机制)不在覆盖范围内。
- 外观方面:共享容器上没有宝箱盖动画(这是服务端的权衡取舍)。
ChestShare
Summary
Per-player loot in every world-generated chest — 100% server-side. Can even restore chests that were looted before you installed it.
Description
Every player gets the dungeon chest. Not just the first one.
On a survival server, the first player to find a structure empties it. Everyone after them explores a looted world. ChestShare gives each player their own instance of every world-generated container — same seed, same loot, nobody left out.
And it's 100% server-side: drop one jar in mods/, done. No client install, works with vanilla clients, launcher-locked modpack players, and cracked-open modpacks alike.
What it does
- Per-player loot instances — chests, trapped chests, barrels, shulkers, dispensers, chest minecarts, and modded containers built on vanilla mechanics. Two players opening the same dungeon chest see the exact same items, each in their own copy.
- Deposit friendly — players can take and stash items in their instance; everything persists with the world.
- Mod-generated structures included — containers are captured at chunk generation, whether they use a loot table or were pre-filled with custom modded items (full NBT).
- No exploits — hoppers and pipes can't touch shared containers; breaking one drops only the breaker's own instance; player-placed chests keep vanilla behavior, always.
- Double chests, done right — combined 54-slot screen, each half tracked separately.
Installed the mod too late? We did too.
ChestShare was born on a live Cobblemon (COBBLEVERSE) server where players had already explored and emptied chests across the whole map. Vanilla deletes a chest's loot table the moment it's opened — that information is gone from the world forever.
But world generation is deterministic. So ChestShare ships a recovery workflow:
- Copy your server setup (same mods, same seed), delete the world copy.
- Pre-generate the explored area on that mirror (Chunky works great) — ChestShare captures every container as it generates.
/chestshare export recovery on the mirror.
/chestshare import recovery on your real server: every chest still standing — including the ones already looted — becomes a shared container with its original loot.
The import runs spread across server ticks (no freeze, no watchdog kill) and skips non-empty containers by default so it never eats player storage. On our server: 332 containers exported from the mirror, 241 restored in one command, zero downtime beyond a restart.
Commands (op level 2)
| Command |
Effect |
/chestshare convert <pos> <loot_table> |
Convert one container (e.g. a chest looted pre-mod) into a shared container |
/chestshare reset <pos> |
Wipe player instances — loot regenerates for everyone |
/chestshare export <file> |
Export all captured containers to a file |
/chestshare import <file> [force] |
Apply an export to this world (recovery) |
Good to know
- Fabric, Minecraft 1.21.1, Java 21. Requires Fabric API. Server-side only (also works in singleplayer/LAN).
- Chunks generated before install: unopened containers still convert automatically on first open (their loot table is intact); already-looted ones need the recovery workflow above.
- Fully custom container implementations (not based on vanilla loot mechanics) aren't covered.
- Cosmetic: no chest lid animation on shared containers (server-side trade-off).
评论 0
登录后参与评分
还没有评论,来抢沙发吧