BanChest
将封禁变成一场寻宝游戏。
当永久封禁一名玩家时,他们的物品栏和末影箱不应消失于虚空——尤其是在世界尺寸有限的服务器上。BanChest 会收集他们携带的所有物品,并将它们分散放置在世界主维度中标有标签的箱子中,供其他玩家发现。
功能
- 一条命令 —
/banchest <player> 处理所有操作
- 支持在线和离线玩家(对离线玩家直接读取
.dat 文件)
- 重新分配物品栏 + 末影箱,包括盔甲、副手和快捷栏
- 在每个箱子下方放置萤石基座,使其在世界中显眼突出
- 为每个箱子附加签名标签,标明归属者及其战利品
- 潜影盒感知 — 可选择将装满物品的潜影盒拆开,放入各自独立的箱子中
防止一次幸运发现就让人拿走一整盒钻石
- 可配置的世界边界形状 — 圆形或方形
- 当玩家战利品超过 27 格时,支持多个箱子,并提供可配置的放置方式(散布在全图或彼此靠近聚集)
- 兼容 LuckPerms 权限节点
- 支持游戏中重载命令 — 配置文件更改后无需重启服务器
- 记录每个箱子的精确坐标到控制台,让你随时知道战利品落在哪里
依赖
- Paper 1.21.1(或与 Paper 1.21.1 兼容的分支)
- Java 21
安装
- 将
banchest-(version).jar 放入服务器的 plugins/ 文件夹
- 重启服务器 — 将生成
plugins/BanChest/config.yml
- 编辑配置文件以匹配你的世界边界,然后运行
/banchest reload
命令与权限
| 命令 |
描述 |
权限 |
默认值 |
/banchest <player> |
将玩家的物品重新分配到主维度箱子中 |
banchest.use |
仅限 OP |
/banchest reload |
无需重启即可重载 config.yml |
banchest.use |
仅限 OP |
LuckPerms 示例
/lp group admin permission set banchest.use true
配置
# 世界边界的半径(以方块为单位)。
# 对于 'circle':圆的半径。
# 对于 'square':半边长(箱子落在两个轴上的 [-radius, +radius] 范围内)。
world-radius: 3000
# 世界边界的形状:'circle' 或 'square'。
world-shape: circle
# 当此项为 true 时,玩家物品栏中的每个装满物品的潜影盒都会被打开,
# 其内容会在各自的随机位置生成为一组独立的箱子。
# 空的潜影盒外壳则保留在常规战利品池中。
# 防止一次宝箱发现就让人拿走一整盒稀有资源。
treat-shulkers-independently: true
# 当玩家的总战利品超过 27 格时,每个溢出箱子是否应放置在完全不同的随机位置?
# true – 每个箱子都落在世界不同的地方(最大分散)。
# false – 溢出箱子彼此靠近聚集。
separate-locations-per-chest: true
工作原理
逐步说明
-
你运行 /banchest <playername>(通常是在通过你偏好的方法封禁他们之后)
-
BanChest 读取玩家的完整物品栏(快捷栏、主槽位、盔甲、副手)
以及末影箱
-
如果启用了 treat-shulkers-independently,每个装满物品的潜影盒都会被提取 —
其内容成为自己独立的箱子组,位于单独的位置,而
空的潜影盒外壳则留在常规战利品中
-
总物品池被分成每组 27 格(每组一个箱子)
-
对于每组,在你的配置的世界边界内选择一个随机地表位置,避开水域、岩浆、悬浮位置和受阻区域
-
在地面上放置一个萤石块,在其上方放置一个箱子,并
附着一个橡木墙式告示牌,上面写着:
Banchest of
PlayerName
feel free to take
-
玩家的物品栏和末影箱中的数据被清除 — 物品现在仅存在于世界中
-
每个箱子的精确坐标会打印到服务器控制台
安全性
- 如果在 60 次尝试后仍无法找到箱子位置,会记录警告并跳过该箱子组(在人口密集的地图中极罕见)
- 只有在箱子成功放置后才会清除玩家数据 — 如果出现问题,玩家数据保持不变,并在控制台中记录错误
- 该命令不会封禁玩家 — 封禁处理完全独立
常见问题
这对当前离线的玩家有效吗?
是的。BanChest 直接读取玩家的 .dat 文件,因此它对任何曾经登录过服务器的玩家都有效,无论其当前是否在线。
如果玩家拥有超过 27 件物品怎么办?
会生成多个箱子。在 separate-locations-per-chest: true(默认)的情况下,每个箱子都会落在世界中完全不同的随机位置。
潜影盒会发生什么?
在 treat-shulkers-independently: true(默认)的情况下,每个装满物品的潜影盒的内容会被提取,并在世界其他地方生成为其自己的箱子。空的潜影盒外壳保留在主战利品箱中。如果禁用此选项,潜影盒会以原样放入箱子中,不打开。
我能看到箱子放在哪里吗?
可以 — 每次放置箱子都会在服务器控制台中记录,包含精确的 X/Y/Z 坐标和世界名称。
运行该命令也会封禁玩家吗?
不会。BanChest 仅处理物品重新分配。请使用你现有的封禁工作流程(/ban、LiteBans、AdvancedBan 等)来单独处理实际的封禁。
BanChest
Turn a ban into a treasure hunt.
When you permanently ban a player, their inventory and ender chest shouldn't disappear into
the void — especially on a server with a limited world size. BanChest takes everything
they were carrying and scatters it across the overworld in labelled chests for other players
to discover.
Features
- One command —
/banchest <player> handles everything
- Works on online and offline players (reads
.dat files directly for offline players)
- Redistributes inventory + ender chest, including armor, off-hand, and hotbar
- Places each chest on a glowstone base so it stands out in the world
- Attaches a signed label to every chest identifying whose loot it is
- Shulker-aware — optionally unpacks filled shulker boxes into their own separate chests
so one lucky find can't hand out a shulker full of diamonds
- Configurable world shape — circle or square border
- Supports multiple chests when the player's loot exceeds 27 slots, with configurable
placement (spread across the world or clustered near each other)
- LuckPerms-compatible permission node
- In-game reload command — no server restart needed after config changes
- Logs exact chest coordinates to console so you always know where the loot landed
Requirements
- Paper 1.21.1 (or a fork compatible with Paper 1.21.1)
- Java 21
Installation
- Drop
banchest-(version).jar into your server's plugins/ folder
- Restart the server — a
plugins/BanChest/config.yml will be generated
- Edit the config to match your world border, then run
/banchest reload
Commands & Permissions
| Command |
Description |
Permission |
Default |
/banchest <player> |
Redistribute the player's inventory into overworld chests |
banchest.use |
OP only |
/banchest reload |
Reload config.yml without restarting |
banchest.use |
OP only |
LuckPerms example
/lp group admin permission set banchest.use true
Configuration
# Radius (in blocks) of your world border.
# For 'circle': the circle's radius.
# For 'square': the half-side-length (chests land within [-radius, +radius] on both axes).
world-radius: 3000
# Shape of the world border: 'circle' or 'square'.
world-shape: circle
# When true, each filled shulker box in the player's inventory is opened and its
# contents are spawned as a separate batch of chest(s) at their own random location(s).
# The emptied shulker shell is left with the regular loot pool.
# Prevents one chest find from handing out an entire shulker's worth of rare resources.
treat-shulkers-independently: true
# When a player's total loot exceeds 27 slots, should each overflow chest be placed
# at a completely different random location?
# true – every chest lands somewhere different in the world (maximum spread).
# false – overflow chests cluster near each other.
separate-locations-per-chest: true
How It Works
Step-by-step
-
You run /banchest <playername> (typically after banning them via your preferred method)
-
BanChest reads the player's full inventory (hotbar, main slots, armor, off-hand)
and ender chest
-
If treat-shulkers-independently is enabled, every filled shulker box is extracted —
its contents become their own independent chest batch at a separate location, and the
empty shulker shell stays with the regular loot
-
The total item pool is split into groups of 27 (one chest per group)
-
For each group, a random surface location is selected within your configured world
border, avoiding water, lava, floating positions, and blocked spots
-
A glowstone block is placed on the ground, a chest is placed on top of it, and
an oak wall sign is attached to the chest reading:
Banchest of
PlayerName
feel free to take
-
The player's inventory and ender chest are cleared from their data — items exist
only in the world now
-
Exact coordinates of every chest are printed to the server console
Safety
- If a chest location cannot be found after 60 attempts, a warning is logged and that
chest group is skipped (extremely rare in a populated world)
- Player data is only cleared after chests are successfully placed — if something goes
wrong, their data is left intact and an error is logged to console
- The command does not ban the player — ban handling is entirely separate
FAQ
Does this work on players who are currently offline?
Yes. BanChest reads the player's .dat file directly, so it works on anyone who has
previously logged into the server, regardless of their current online status.
What if the player had more than 27 items?
Multiple chests are spawned. With separate-locations-per-chest: true (default), each
chest lands at a completely different random location in the world.
What happens to shulker boxes?
With treat-shulkers-independently: true (default), the contents of each filled shulker
are extracted and spawned as their own chest(s) elsewhere in the world. The empty shulker
shell stays in the main loot chest. With the option disabled, shulkers are placed in chests
as-is, unopened.
Can I see where chests were placed?
Yes — every chest placement is logged to the server console with exact X/Y/Z coordinates
and the world name.
Will running the command also ban the player?
No. BanChest only handles item redistribution. Use your existing ban workflow
(/ban, LiteBans, AdvancedBan, etc.) to handle the actual ban separately.
评论 0
登录后参与评分
还没有评论,来抢沙发吧