
一款轻量级的 服务端 Fabric 模组,允许玩家在死亡后保留经验等级,并提供可选的 惩罚 机制:改为扣除一定比例的等级而非全部。适用于专用服务器(原版客户端可加入,无需安装此模组)以及单人游戏。可通过简单命令进行配置,也可通过任何权限模组(如 LuckPerms)按玩家或组别进行设置。
再也不用担心因死亡而丢失等级和数小时的刷怪投入了!
主要功能
- 死亡保留经验: 玩家死亡后保留等级,而不是失去它们。
- 可调节惩罚 (0–100%): 可选择在死亡时移除一定比例的等级。
0%:关闭惩罚,等级和经验条保持不变。>0%:移除该百分比的等级(向下取整),并将经验条重置为 0。- 被移除的等级会按照原版公式生成经验球掉落(每级 7 点,上限 100)。
- 仅限服务端: 只需在服务端安装。原版客户端可以加入,无需安装此模组。
- 单人与局域网: 安装在客户端上即可运行,它会在游戏内置服务器上运行。
- 两种模式(自动检测):
- 默认模式: KeepXP 和惩罚设置对所有人全局生效,通过命令控制。
- 权限模式: KeepXP 和惩罚设置针对每个玩家或组别,通过权限控制(见 权限 部分)。
命令
| 命令 | 描述 | 使用者 |
|---|---|---|
/keepxp 或 /keepxp status |
显示当前的 KeepXP 状态 | 所有人 |
/keepxp help |
显示可用命令 | OP 等级 2 或拥有 keepxp.command 权限 |
/keepxp turn [on | off] |
为所有玩家开启/关闭 KeepXP (仅限默认模式) | OP 等级 2 或拥有 keepxp.command 权限 |
/keepxp penalty [0-100] |
显示或设置死亡时移除的等级百分比 (仅限默认模式) | OP 等级 2 或拥有 keepxp.command 权限 |
在权限模式下,
turn和penalty命令不会改变任何设置,并会显示警告提示你应使用哪个权限。
权限
如果安装了权限模组(如 LuckPerms),KeepXP 会自动检测到并切换到权限模式。 玩家可以在游戏中通过
/keepxp或/keepxp status查看自己的 KeepXP 设置。
| 权限 | 描述 |
|---|---|
keepxp.keep |
玩家死亡时保留经验。没有此权限的玩家将按原版方式丢失经验。 |
keepxp.penalty.<0-100> |
玩家或组的惩罚百分比,例如 keepxp.penalty.30。仅在与 keepxp.keep 同时存在时生效。如果未设置,则无惩罚。如果玩家拥有多个惩罚权限,以最低值为准。 |
keepxp.command |
访问管理命令 (help, turn, penalty)。在没有权限模组的情况下,需要 OP 等级 2。 |
使用方法
- 默认模式: 安装模组后,所有玩家的经验都会被保留且无惩罚。使用
/keepxp turn和/keepxp penalty来更改这些设置。 - 权限模式: 向玩家或组别授予
keepxp.keep,并可选地授予keepxp.penalty.<0-100>。
常见问题 (FAQ)
- 问:模组在单人游戏中有效吗?
- 答: 是的。将其安装在你的客户端上即可。它在单人和局域网世界中均有效。
- 问:玩家加入我的服务器时需要安装此模组吗?
- 答: 不需要。它仅限服务端使用,因此原版客户端可以直接加入。
- 问:惩罚机制具体是如何工作的?
- 答: 假设惩罚为 30%,一个 20 级的玩家会损失 6 个等级(向下取整)。他们将在 14 级重生,经验条为空,并在死亡地点掉落 42 点经验值(7 × 6)作为经验球。如果是 0% 惩罚,则没有任何损失或掉落。
- 问:低等级时会发生什么?
- 答: 被移除的等级会向下取整,因此 30% 的 3 级只会移除 0 个等级。只有经验条会被重置。
- 问:如果启用了
keepInventory游戏规则怎么办?- 答: 原版行为优先:玩家保留所有物品,且不应用任何惩罚。
- 问:支持哪些权限模组?
- 答: 任何使用 Fabric Permission API 或 fabric-permissions-api 的模组都支持(LuckPerms 同时支持两者)。仅提供 API 库而不提供权限功能的模组将被忽略。
- 问:我安装了权限模组,但没人再保留经验了,为什么?
- 答: 在权限模式下,只有拥有
keepxp.keep权限的玩家才会保留经验。给你的默认组别授予此权限即可恢复旧的行为。
- 答: 在权限模式下,只有拥有
- 问:拥有权限的玩家可以使用
/keepxp turn或/keepxp penalty吗?- 答: 在安装权限模组的情况下,这些命令无效。所有内容都通过权限进行设置。

如果你想支持 Keep XP 的持续开发,可以考虑在我的 ☕ Ko-fi 页面 上进行捐赠。 任何金额都将受到极大的感谢,并帮助我投入更多时间制作精彩的模组。 ⭐ 支持者还会在我的 Discord 服务器中获得特殊的“支持者”角色!
有问题、遇到了 Bug,或者只是想聊聊这个模组? 加入我们的 Discord 社区吧!
如需报告 Bug 或处理技术问题,你也可以在 GitHub 上提交 Issue。

A lightweight server-side Fabric mod that lets players keep their experience levels after death, with an optional penalty that takes a percentage of levels instead of everything. Works on dedicated servers (vanilla clients can join, no client install needed) and in singleplayer. Configure it with simple commands, or per player and per group through any permission mod such as LuckPerms.
No more worrying about losing levels and hours spent farming!
Key Features
- Keep XP on Death: Players keep their levels after death instead of losing them.
- Adjustable Penalty (0–100%): Optionally remove a percentage of levels on death.
0%: penalty is off, levels and XP bar stay untouched.>0%: that percentage of levels is removed (rounded down) and the XP bar is reset to 0.- Removed levels drop as XP orbs using the vanilla formula (7 points per level, max 100).
- Server-Side Only: Install it only on the server. Vanilla clients can join without the mod.
- Singleplayer & LAN: Install it on the client, it runs on the game's built-in server.
- Two Modes (detected automatically):
- Default Mode: KeepXP and the penalty are set globally for all players with commands.
- Permissions Mode: KeepXP and the penalty are set per player or group with permissions (see the Permissions section).
Commands
| Command | Description | Who can use it |
|---|---|---|
/keepxp or /keepxp status |
Show the current KeepXP status | Everyone |
/keepxp help |
Show available commands | Op level 2 or keepxp.command |
/keepxp turn [on | off] |
Turn KeepXP on/off for all players (Default Mode only) | Op level 2 or keepxp.command |
/keepxp penalty [0-100] |
Show or set the % of levels removed on death (Default Mode only) | Op level 2 or keepxp.command |
In Permissions Mode,
turnandpenaltydon't change anything and show a warning telling you which permission to use instead.
Permissions
If a permission mod is installed (such as LuckPerms), KeepXP detects it automatically and switches to Permissions Mode. Players can check their own KeepXP setting in game with
/keepxpor/keepxp status.
| Permission | Description |
|---|---|
keepxp.keep |
Player keeps XP on death. Players without it lose XP the vanilla way. |
keepxp.penalty.<0-100> |
Penalty in % for the player or group, e.g. keepxp.penalty.30. Only applies together with keepxp.keep. If none is set, there is no penalty. If a player has several, the lowest one wins. |
keepxp.command |
Access to admin commands (help, turn, penalty). Without a permission mod, op level 2 is required. |
Usage
- Default Mode: After installing the mod, XP is kept for all players with no penalty. Use
/keepxp turnand/keepxp penaltyto change this. - Permissions Mode: Give
keepxp.keepto players or groups, and optionallykeepxp.penalty.<0-100>.
Frequently Asked Questions (FAQ)
- Q: Does the mod work in singleplayer?
- A: Yes. Install it on your client. It works in singleplayer and LAN worlds.
- Q: Do players need to install the mod to join my server?
- A: No. It is server-side only, so vanilla clients can join.
- Q: How exactly does the penalty work?
- A: With a 30% penalty, a player at level 20 loses 6 levels (rounded down). They respawn at level 14 with an empty XP bar, and 42 XP points (7 × 6) drop as orbs where they died. With 0%, nothing is lost or dropped.
- Q: What happens at low levels?
- A: Removed levels are rounded down, so 30% of level 3 removes 0 levels. Only the XP bar is reset.
- Q: What if the
keepInventorygamerule is on?- A: Vanilla behaviour takes priority: players keep everything and no penalty is applied.
- Q: Which permission mods are supported?
- A: Any mod that uses the Fabric Permission API or the fabric-permissions-api (LuckPerms supports both). Mods that only bundle the API library without providing permissions are ignored.
- Q: I installed a permission mod and nobody keeps XP anymore. Why?
- A: In Permissions Mode, XP is kept only for players with
keepxp.keep. Give it to your default group to restore the old behaviour.
- A: In Permissions Mode, XP is kept only for players with
- Q: Can players with permissions use
/keepxp turnor/keepxp penalty?- A: These commands have no effect while a permission mod is installed. Everything is set through permissions instead.

If you'd like to support the continued development of Keep XP, consider contributing on my ☕ Ko-fi page. Any amount is greatly appreciated and helps me dedicate more time to creating awesome mods. ⭐ Supporters also receive a special Supporter role on my Discord server!
Have questions, encountered a bug, or just want to chat about the mod? Join our community on Discord!
For bug reports and technical issues, you can also open an issue on GitHub.
下载 Keep XP on Death
下载 Keep XP on Death
下载 Keep XP on Death
下载 Keep XP on Death
下载 Keep XP on Death
下载 Keep XP on Death
下载 Keep XP on Death
下载 Keep XP on Death
下载 Keep XP on Death
下载 Keep XP on Death
全面重写以适配 26.3 Minecraft 版本。
重要更改:
- 添加了可选惩罚(
/keepxp penalty [0-100]) - 移除了
/keepxp override [on|off](现在自动生效)
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
模组
显示你正在注视的方块的信息。(适用于 Minecraft 1.16+ 的 Hwyla/Waila 分支)
模组
在游戏画面角落显示附近世界地形、玩家、生物和实体的地图。可创建路径点,帮助你找到标记过的位置。
模组
查看物品与配方
模组
使用 JavaScript 编辑配方、添加自定义物品、编写世界事件!
模组
AE2:一款流行的自动化与存储模组
模组
那是什么?一个 Waila/Hwyla 的分支。
评论 0
登录后参与评分
还没有评论,来抢沙发吧