☠ DeathInventoryTracker
再也不必担心丢失的物品找不回来。
DeathInventoryTracker 是一款功能强大的 PaperMC 插件,它会为玩家的每一次死亡保存完整的快照——包括背包、盔甲、副手物品、经验值、击杀者信息以及死亡消息,并允许管理员通过简洁的游戏内 GUI 浏览、检查和恢复这些数据。支持完全离线玩家、Discord 通知和 Tab 补全功能。
✨ 功能特性
? 完整的死亡快照
每次死亡都会被记录以下信息:
- 完整的背包内容(所有 36 个槽位——快捷栏 + 储物栏)
- 盔甲槽位(靴子、护腿、胸甲、头盔)
- 副手物品
- 死亡时的经验值
- 击杀者名称及类型(玩家 / 怪物 / 环境)
- 死亡消息
- 时间戳
所有物品数据均以高保真度保留:附魔、耐久度、自定义名称、描述文本(Lore)以及 NBT 标签在存储和读取过程中均完好无损。
? 游戏内 GUI 浏览器
在一个整洁的 54 格箱子 GUI 中打开任意玩家的死亡历史:
- 玩家头像图标代表每次死亡——贴图对应已故玩家
- 颜色编码条目一目了然:
- ? 红色标题 → 被玩家击杀
- ? 金色标题 → 被怪物击杀
- ? 绿色标题 → 环境因素 / 坠落 / 火焰等
- 描述文本预览显示击杀者、物品数量、损失的经验值和死亡消息——无需打开条目即可查看
- 分页功能——跨多页浏览任意数量的死亡记录
- 过滤按钮——一键切换“全部死亡”、“玩家击杀”和“自然死亡”
- 返回按钮——从死亡详情视图返回列表,无需重新输入命令
死亡详情查看器
点击任意条目以打开完整的 54 格详情视图,显示:
- 原始槽位中的所有 36 个背包物品
- 盔甲(槽位 36–39)
- 副手物品(槽位 40)
- 包含完整死亡元数据的说明书籍
- 恢复按钮——将所有物品和经验值直接发送给已故玩家(玩家必须在线)
? 智能背包恢复
- 恢复操作针对死亡的玩家,而非正在查看 GUI 的管理员
- 管理员会收到确认消息;接收者会收到通知,告知是谁恢复了其物品
- 如果玩家离线,恢复将被阻止并显示清晰的错误消息
? 完全支持离线玩家
- 死亡记录按玩家存储在 JSON 文件中(
PlayerName_uuid.json)
- 即使玩家离线,也能浏览和检查任何玩家的死亡记录
- Tab 补全会显示在线玩家和拥有存储死亡记录的离线玩家
⌨ 命令
| 命令 |
描述 |
权限 |
/deathinv |
打开自己的死亡浏览器 |
deathinv.view.self |
/deathinv view <player> |
浏览某玩家的死亡记录 |
deathinv.view.others |
/deathinv latest <player> |
显示最近的死亡详情 |
deathinv.view.others |
/deathinv list <player> |
列出最近 10 次死亡 |
deathinv.view.others |
/deathinv reload |
重载配置和所有数据 |
deathinv.admin |
/deathinv cleanup [days] |
删除超过 N 天的记录 |
deathinv.admin |
所有命令均可从服务器控制台执行,并输出格式化的纯文本。
? 权限
| 权限 |
默认设置 |
描述 |
deathinv.view.self |
所有人 |
打开自己的死亡背包 |
deathinv.view.others |
OP |
查看其他玩家的死亡记录 |
deathinv.admin |
OP |
重载配置、清理数据 |
? Discord 集成
每当有玩家死亡时,在 Discord 中接收通知:
- 嵌入消息包含玩家名称、击杀者、死亡消息、物品数量、贵重物品、损失的经验值和时间戳
- 红色嵌入表示玩家击杀,橙色表示自然死亡
- Webhook 发送异步运行——对服务器 Tick 零影响
- 在
config.yml 中启用/禁用并设置 Webhook URL
? 数据存储
死亡记录以紧凑的 JSON 文件格式保存在 plugins/DeathInventoryTracker/deaths/ 目录中:
- 每个玩家一个文件,命名为
PlayerName_uuid.json
- 仅存储非空槽位——无浪费的空条目
- 使用 Bukkit 原生序列化(Base64)序列化物品,保留所有元数据
- 人类可读的槽位映射格式:
{ "0": "<base64>", "7": "<base64>" }
- 启动时自动加载,每次死亡后立即保存
- 损坏的文件会被跳过并附带控制台警告——不会导致服务器崩溃
⚙ 配置
# Discord Integration
discord:
enabled: false
webhook-url: "https://discord.com/api/webhooks/YOUR_ID/TOKEN"
# General Settings
settings:
auto-cleanup-days: 30 # 删除超过 N 天的死亡记录(0 = 永不删除)
log-deaths: true # 将每次死亡记录到控制台
? 要求
| 要求 |
版本 |
| 服务端软件 |
PaperMC |
| Minecraft |
1.20.4+ |
| Java |
17+ |
此插件使用了 Paper 特有的 API,无法在 Spigot 或 CraftBukkit 上运行。
? 安装
- 下载
.jar 文件
- 将其放入服务器的
plugins/ 文件夹
- 重启服务器
- 根据需要编辑
plugins/DeathInventoryTracker/config.yml
- 使用
/deathinv reload 应用配置更改而无需重启服务器
由 rradajbi 制作
☠ DeathInventoryTracker
Never lose track of what you lost — ever again.
DeathInventoryTracker is a powerful PaperMC plugin that saves a complete snapshot of every player death — inventory, armor, offhand, XP, killer info, and death message and lets admins browse, inspect, and restore them through a clean in-game GUI. Full offline player support, Discord notifications, and tab completion included.
✨ Features
? Complete Death Snapshots
Every death is recorded with:
- Full inventory contents (all 36 slots — hotbar + storage)
- Armor slots (boots, leggings, chestplate, helmet)
- Offhand item
- XP at time of death
- Killer name & type (Player / Mob / Environment)
- Death message
- Timestamp
All item data is preserved with full fidelity enchantments, durability, custom names, lore, and NBT all survive the round-trip.
? In-Game GUI Browser
Open any player's death history in a clean 54-slot chest GUI:
- Player head icons for each death — skinned to the dead player
- Color-coded entries at a glance:
- ? Red title → killed by a player
- ? Gold title → killed by a mob
- ? Green title → environment / fall / fire / etc.
- Lore preview showing killer, item count, XP lost, and death message — without opening the entry
- Pagination — browse any number of deaths across multiple pages
- Filter buttons — switch between All Deaths, Player Kills, and Natural Deaths instantly
- Back button — return to the list from a death detail view without retyping commands
Death Detail Viewer
Click any entry to open a full 54-slot detail view showing:
- All 36 inventory items in their original slots
- Armor (slots 36–39)
- Offhand item (slot 40)
- Info book with full death metadata
- Restore button — sends all items + XP directly to the dead player (must be online)
? Smart Inventory Restore
- Restore goes to the player who died, not whoever is viewing the GUI
- Admin gets a confirmation message; the recipient gets a notification telling them who restored it
- If the player is offline, restore is blocked with a clear error message
? Full Offline Player Support
- Deaths are stored in JSON files per player (
PlayerName_uuid.json)
- Browse and inspect any player's deaths even when they're offline
- Tab completion shows both online players and offline players who have stored death records
⌨ Commands
| Command |
Description |
Permission |
/deathinv |
Open your own death browser |
deathinv.view.self |
/deathinv view <player> |
Browse a player's deaths |
deathinv.view.others |
/deathinv latest <player> |
Show the most recent death details |
deathinv.view.others |
/deathinv list <player> |
List last 10 deaths |
deathinv.view.others |
/deathinv reload |
Reload config and all data |
deathinv.admin |
/deathinv cleanup [days] |
Delete records older than N days |
deathinv.admin |
All commands work from the server console with formatted plain-text output.
? Permissions
| Permission |
Default |
Description |
deathinv.view.self |
Everyone |
Open your own death inventory |
deathinv.view.others |
OP |
View another player's deaths |
deathinv.admin |
OP |
Reload, cleanup |
? Discord Integration
Get notified in Discord every time a player dies:
- Embedded message with player name, killer, death message, item count, valuable items, XP lost, and timestamp
- Red embed for player kills, orange for natural deaths
- Webhook sending runs asynchronously — zero server tick impact
- Enable/disable and set the webhook URL in
config.yml
? Data Storage
Deaths are saved as compact JSON files in plugins/DeathInventoryTracker/deaths/:
- One file per player, named
PlayerName_uuid.json
- Only non-empty slots are stored — no wasted null entries
- Items serialized with Bukkit's native serialization (Base64) preserving all metadata
- Human-readable slot map format:
{ "0": "<base64>", "7": "<base64>" }
- Auto-loaded on startup, saved immediately on each death
- Corrupted files are skipped with a console warning — they won't crash the server
⚙ Configuration
# Discord Integration
discord:
enabled: false
webhook-url: "https://discord.com/api/webhooks/YOUR_ID/TOKEN"
# General Settings
settings:
auto-cleanup-days: 30 # delete deaths older than N days (0 = never)
log-deaths: true # log each death to console
? Requirements
| Requirement |
Version |
| Server software |
PaperMC |
| Minecraft |
1.20.4+ |
| Java |
17+ |
This plugin uses Paper-specific APIs and will not work on Spigot or CraftBukkit.
? Installation
- Download the
.jar file
- Place it in your server's
plugins/ folder
- Restart the server
- Edit
plugins/DeathInventoryTracker/config.yml as needed
- Use
/deathinv reload to apply config changes without restarting
Made by rradajbi
评论 0
登录后参与评分
还没有评论,来抢沙发吧