StrengthShards
适用于 Paper 26.2(Minecraft 26.2)的赏金猎人成长系统。 每次击杀玩家都会永久获得 +1 力量(额外攻击伤害);被其他玩家杀死则会失去一点。老手打击更重,受害者打击更轻——整个力量经济通过可制作、可交易、可食用的 Strength Shards 由玩家驱动。
- 需要 Paper 26.2 服务器(或更新的 26.x 版本)和 Java 25
- 无需客户端模组——可选的资源包仅用于提升碎片的纹理效果
- 所有内容均可配置,且重启后保留
核心循环
| 事件 |
效果 |
| 你击杀了一名玩家 |
+1 力量(永久额外攻击伤害) |
| 你被一名玩家杀死 |
−1 力量 |
| 你吃下一枚 Strength Shard |
+1 力量 |
| 你提取力量 |
力量转化为实体碎片,你可以将其交易、赠送或赌博输掉 |
力量数据以玩家 UUID 为单位存储在 plugins/StrengthShards/data.yml 中,并在死亡、登录和服务器重启后持久保存。力量值为 ±0 时是中立默认状态。
赏金猎人的转折
- 你无法从空壳玩家身上刷取力量。 击杀一名已经处于最低力量的玩家将 一无所获——他们已无剩余的力量可供夺取。击杀者会收到提示,这也起到了情报作用:该目标在食用碎片前毫无价值。
- 达到上限的击杀者仍会获得报酬。 一名已达到 最大力量 的玩家击杀他人时,无法吸收更多力量,因此受害者会掉落一枚 Strength Shard——直接落入击杀者的背包中。如果击杀者背包已满,碎片会掉落至死亡地点的地面上,任何人都可以拾取。
- 虚弱是被感知的,而非致命的。 负数力量会以百分比降低你的总近战伤害,因此力量耗尽的玩家仍能反击——只是打击力度更轻。(为何不是固定值减少?请见下文。)
伤害机制
加成应用于 attack_damage 属性——即力量药水所使用的相同机制——因此它与剑、斧头和附魔叠加。
- 正数力量: 每点提供 +1 攻击伤害(
+3 力量 = 每次近战命中 +3 伤害)。
- 负数力量: 零点以下每点造成 −15% 总近战伤害(默认值;−3 时为 −45%,总体上限为 −90%)。
为何负数力量不是固定值减少? 自 Minecraft 1.21.2 起,attack_damage 属性被硬性限制最小值为 0,并且游戏会静默跳过玩家的 整次攻击(无伤害、无击退、无声音——即使在创造模式下),只要该值不严格大于 0。对于基础值为 1.0 的空手攻击,固定 −3 会使玩家完全无法击中任何目标。百分比惩罚能确保数值保持在零以上,使虚弱的玩家始终留在战斗中。
插件使用临时属性修饰符,在加入/重生时重新应用,在禁用时移除——从不触碰基础值或物品属性,如果你卸载插件,玩家数据中也不会留下任何残留。
Strength Shard
一种自定义物品(以烈焰粉为基础),食用后提供 +1 力量——像食物一样按住右键即可,即使饥饿值已满也能生效。达到最大上限的碎片拒绝被消耗(不会被浪费),且完全可堆叠,使其成为天然的货币:购买、出售、赠送、赌博或囤积。
获取碎片的方式:
-
制作 — 用 1 颗钻石周围环绕 4 个烈焰粉(可在配置文件中切换):
. blaze powder .
blaze powder diamond blaze powder
. blaze powder .
-
提取自己的力量 — /strength withdraw 2 将你的 2 点力量转化为 2 枚碎片
-
击杀已达上限的玩家或自身已达上限 — 参见上述赏金规则
-
管理员命令 — /strength give,或使用原版 /give(见下文)
碎片带有识别用的数据标签,因此由插件创建、管理员生成或通过原版 /give 生成的物品均被识别并可互换使用。
命令
主命令:/strength — 别名 /str, /shards
| 命令 |
描述 |
权限 |
/strength 或 /strength check |
查看自己的力量和当前加成 |
strength.use |
/strength check <player> |
查看其他玩家的力量(在线或离线) |
strength.admin |
/strength withdraw <amount|all> |
将你的力量转换为 Strength Shards(仅正数力量可提取) |
strength.use |
/strength givecmd [amount] |
打印生成碎片的确切原版 /give 命令,作为点击复制消息 |
strength.use |
/strength pack |
重新发送资源包提示 |
strength.use |
/strength set <player> <amount> |
设置玩家的力量值(受配置的上下限约束;支持离线操作) |
strength.admin |
/strength give <player> <amount> |
直接给予 Strength Shards |
strength.admin |
/strength reload |
重载配置(上下限、物品、配方、消息) |
strength.admin |
子命令、玩家名称和常见数量均提供 Tab 补全。
权限
| 权限 |
用途 |
默认值 |
strength.use |
查看自己的力量、提取碎片、打印给予命令、重新发送资源包 |
所有人 |
strength.admin |
设置/给予力量、查看其他玩家、重载配置 |
服务器操作员 |
配置
plugins/StrengthShards/config.yml — 更改任何内容后运行 /strength reload(或重启服务器):
| 设置项 |
默认值 |
描述 |
caps.max-strength |
3 |
可达到的最高力量值 |
caps.min-strength |
-3 |
最低可沉没的力量值 |
pvp.kill-gain |
1 |
每次击杀玩家获得的力量值(受受害者实际损失的限制) |
pvp.death-loss |
1 |
被玩家击杀时失去的力量值 |
pvp.negative-strength-penalty-per-point |
0.15 |
每点负力量值损失的伤害比例(总计最多 -90%) |
pvp.shard-drop.enabled |
true |
达到最大力量的击杀者改为从受害者处获得碎片 |
pvp.shard-drop.amount |
1 |
每次最大力量击杀掉落的碎片数量 |
item.name / item.lore / item.glint |
— |
碎片的显示名称、描述文本和附魔光泽效果 |
item.custom-model-data |
2301 |
资源包用于匹配的数据值 |
crafting.enabled |
true |
切换合成配方是否启用 |
resource-pack.auto-send |
true |
在玩家加入时提示安装资源包 |
resource-pack.url / sha1 / required / prompt |
— |
资源包分发设置 |
messages.* |
— |
所有消息,包括前缀,均采用 MiniMessage 格式 |
资源包(可选)
如果没有安装资源包,碎片看起来就像带有自定义名称的附魔烈焰粉——功能完全正常。安装随附的资源包后,它们将渲染为真正的晶体碎片。
- 获取随附的
strength-shards-resourcepack.zip,并将其托管在玩家可以下载的任何位置(你的 Web 服务器、文件托管服务或 CDN)
- 将 URL(以及可选的 SHA-1 哈希值)填入
config.yml 中的 resource-pack.url / resource-pack.sha1 下
- 重启服务器或执行
/strength reload —— 玩家在加入时会收到提示,且可以通过 /strength pack 重新发送提示
该资源包使用 1.21.4+ 的 items/ 模型系统(基于 custom_model_data 的 range_dispatch),专为资源包格式 88 / Minecraft 26.2 构建。如果未来客户端警告该资源包是为旧版本创建的,只要接受即可生效——如果该警告让你困扰,只需更新 pack.mcmeta 即可。
无需插件经济系统获取碎片(管理员)
服务器插件无法注册自定义物品 ID,且原版创造模式菜单是客户端硬编码的,因此碎片无法出现在其中。相反,在游戏中运行 /strength givecmd —— 它会根据你当前的配置打印一条可直接粘贴的原版命令,例如:
give <player> minecraft:blaze_powder[minecraft:custom_name={text:"Strength Shard",color:"gold",italic:false},minecraft:lore=[{text:"Consume to permanently gain +1 Strength",color:"gray",italic:false},{text:"Hold right-click to eat. Tradeable!",color:"gray",italic:false}],minecraft:custom_data={PublicBukkitValues:{"strengthshards:strength_shard":1b}},minecraft:custom_model_data={floats:[2301f]},minecraft:food={nutrition:0,saturation:0.0f,can_always_eat:true},minecraft:consumable={consume_seconds:1.6f,animation:"eat",sound:"minecraft:entity.generic.eat",has_consume_particles:true},minecraft:enchantment_glint_override=true]
以此方式创建的物品与合成/提取的碎片完全相同——插件会识别并接受它们。
安装方法
- 将
StrengthShards-x.x.x.jar 放入服务器的 plugins/ 文件夹中
- 重启服务器(Paper 26.2, Java 25)
- 可选:配置资源包 URL(见上文)并运行
/strength reload
数据以纯 YAML 格式存储在 plugins/StrengthShards/data.yml 中——人类可读、可编辑,且易于备份。移除插件会干净地将所有玩家的状态恢复为原版数值。
常见问题
它兼容 Spigot 吗? 不兼容——它针对的是 Paper 26.2(使用了 Paper 的 data-component 和 Adventure API)。
两个玩家可以交易力量吗? 可以——一方提取碎片并交给另一方;另一方吃掉它们。这正是它的核心机制!
我可以更改合成配方的材料吗? 配方本身是固定的(4 烈焰粉 + 1 钻石),但可以完全禁用(crafting.enabled: false);请使用 /strength give 或原版 give 命令以其他方式分发碎片。
如果击杀者已达最大值,而受害者处于最小值怎么办? 受害者已无物可给,因此不会发生力量转移——但达到最大力量的击杀者仍然会获得碎片掉落奖励。
StrengthShards
Bounty-hunter progression for Paper 26.2 (Minecraft 26.2). Every player kill grants permanent +1 Strength (bonus attack damage); every death to another player takes one away. Veterans hit harder, victims hit softer — and the whole strength economy is player-driven through craftable, tradeable, edible Strength Shards.
- Requires a Paper 26.2 server (or newer 26.x) and Java 25
- No client mods required — the optional resource pack just improves the shard's texture
- Everything is configurable and survives restarts
The core loop
| Event |
Effect |
| You kill a player |
+1 Strength (permanent bonus attack damage) |
| You die to a player |
−1 Strength |
| You eat a Strength Shard |
+1 Strength |
| You withdraw strength |
Strength becomes physical shards you can trade, gift or gamble away |
Strength is stored per-player UUID in plugins/StrengthShards/data.yml and persists across deaths, logins and server restarts. Being at ±0 strength is the neutral default.
The bounty-hunter twist
- You can't farm empty players. Killing someone who is already at minimum strength grants nothing — they have no strength left to give. The killer is told so, which doubles as intel: that target is worthless until they eat shards.
- Capped killers still get paid. A player already at max strength who kills someone can't absorb more strength, so the victim drops a Strength Shard instead — straight into the killer's inventory. If the killer's inventory is full, the shard drops on the ground at the death spot where anyone can steal it.
- Weakness is felt, not crippling. Negative strength reduces your total melee damage by a percentage, so drained players can still fight back — they just hit softer. (See below for why it isn't a flat reduction.)
How the damage works
The bonus is applied to the attack_damage attribute — the same mechanic Strength potions use — so it stacks with swords, axes and enchantments.
- Positive strength: flat +1 attack damage per point (
+3 Strength = +3 damage on every melee hit).
- Negative strength: −15% total melee damage per point below zero (default; at −3 that's −45%, capped at −90% overall).
Why isn't negative strength flat? Since Minecraft 1.21.2, the attack_damage attribute is hard-clamped to a minimum of 0, and the game silently skips your entire attack (no damage, no knockback, no sound — even in creative mode) whenever the value isn't strictly above 0. A flat −3 on a bare fist (base 1.0) would make the player completely unable to hit anything. A percentage penalty keeps the value above zero, so weakened players always stay in the fight.
The plugin uses transient attribute modifiers that are re-applied on join/respawn and stripped on disable — no base values or item stats are ever touched, and nothing is left behind in your playerdata if you remove the plugin.
The Strength Shard
A custom item (blaze powder base) that grants +1 Strength when eaten — hold right-click like food, works even on a full hunger bar. Shards at the max cap refuse to be consumed (they aren't wasted) and are fully stackable, making them a natural currency: buy, sell, gift, gamble or hoard them.
Get shards by:
-
Crafting — 4 blaze powder around 1 diamond (toggleable in the config):
. blaze powder .
blaze powder diamond blaze powder
. blaze powder .
-
Withdrawing your own strength — /strength withdraw 2 turns 2 of your strength into 2 shards
-
Killing capped players or being capped yourself — see the bounty rules above
-
Admin commands — /strength give, or vanilla /give (see below)
Shards carry an identifying data tag, so items created by the plugin, by admins, or via vanilla /give are all recognized and interchangeable.
Commands
Main command: /strength — aliases /str, /shards
| Command |
Description |
Permission |
/strength or /strength check |
Check your own strength and current bonus |
strength.use |
/strength check <player> |
Check another player's strength (online or offline) |
strength.admin |
/strength withdraw <amount|all> |
Convert your strength into Strength Shards (only positive strength can be withdrawn) |
strength.use |
/strength givecmd [amount] |
Prints the exact vanilla /give command for shards as a click-to-copy message |
strength.use |
/strength pack |
Re-send the resource pack prompt |
strength.use |
/strength set <player> <amount> |
Set a player's strength (clamped to your configured caps; works offline) |
strength.admin |
/strength give <player> <amount> |
Give Strength Shards directly |
strength.admin |
/strength reload |
Reload the configuration (caps, item, recipe, messages) |
strength.admin |
Tab completion is provided for subcommands, player names and common amounts.
Permissions
| Permission |
Purpose |
Default |
strength.use |
Check your own strength, withdraw shards, print the give command, re-send the resource pack |
everyone |
strength.admin |
Set/give strength, check other players, reload the config |
server operators |
Configuration
plugins/StrengthShards/config.yml — change anything and run /strength reload (or restart):
| Setting |
Default |
Description |
caps.max-strength |
3 |
Highest reachable strength |
caps.min-strength |
-3 |
Lowest sinkable strength |
pvp.kill-gain |
1 |
Strength gained per player kill (gated by the victim's actual loss) |
pvp.death-loss |
1 |
Strength lost when killed by a player |
pvp.negative-strength-penalty-per-point |
0.15 |
Damage fraction lost per negative strength point (max total −90%) |
pvp.shard-drop.enabled |
true |
Max-strength killers receive a shard from the victim instead |
pvp.shard-drop.amount |
1 |
Shards dropped per max-strength kill |
item.name / item.lore / item.glint |
— |
Shard display name, lore and enchant glint |
item.custom-model-data |
2301 |
Model-data value the resource pack matches against |
crafting.enabled |
true |
Toggle the crafting recipe |
resource-pack.auto-send |
true |
Prompt players to install the pack on join |
resource-pack.url / sha1 / required / prompt |
— |
Resource pack delivery settings |
messages.* |
— |
Every message, including the prefix, in MiniMessage format |
Resource pack (optional)
Without a resource pack, shards look like an enchanted blaze powder with a custom name — fully functional. Install the included resource pack and they render as a proper crystal shard.
- Take the included
strength-shards-resourcepack.zip and host it anywhere players can download it (your web server, a file host, a CDN)
- Put the URL (and optionally its SHA-1 hash) into
config.yml under resource-pack.url / resource-pack.sha1
- Restart or
/strength reload — players are prompted on join, and /strength pack re-sends the prompt
The pack uses the 1.21.4+ items/ model system (range_dispatch on custom_model_data), built for resource pack format 88 / Minecraft 26.2. If a future client warns the pack was made for an older version, it still applies once accepted — just bump pack.mcmeta if the warning bothers you.
Obtaining shards without the plugin economy (admins)
Server plugins cannot register custom item IDs and the vanilla creative menu is hardcoded client-side, so shards can't appear in either. Instead, run /strength givecmd in-game — it prints a ready-to-paste vanilla command built from your current config, e.g.:
give <player> minecraft:blaze_powder[minecraft:custom_name={text:"Strength Shard",color:"gold",italic:false},minecraft:lore=[{text:"Consume to permanently gain +1 Strength",color:"gray",italic:false},{text:"Hold right-click to eat. Tradeable!",color:"gray",italic:false}],minecraft:custom_data={PublicBukkitValues:{"strengthshards:strength_shard":1b}},minecraft:custom_model_data={floats:[2301f]},minecraft:food={nutrition:0,saturation:0.0f,can_always_eat:true},minecraft:consumable={consume_seconds:1.6f,animation:"eat",sound:"minecraft:entity.generic.eat",has_consume_particles:true},minecraft:enchantment_glint_override=true]
Items created this way are identical to crafted/withdrawn shards — the plugin recognizes and accepts them.
Installation
- Drop
StrengthShards-x.x.x.jar into your server's plugins/ folder
- Restart the server (Paper 26.2, Java 25)
- Optionally configure the resource pack URL (see above) and run
/strength reload
Data is plain YAML in plugins/StrengthShards/data.yml — human-readable, editable, and trivial to back up. Removing the plugin cleanly reverts every player to vanilla stats.
FAQ
Does it work with Spigot? No — it targets Paper 26.2 (it uses Paper's data-component and Adventure APIs).
Can two players trade strength? Yes — one withdraws shards and hands them over; the other eats them. That's the whole point!
Can I change the crafting recipe ingredients? The recipe itself is fixed (4 blaze powder + 1 diamond) but can be disabled entirely (crafting.enabled: false); use /strength give or the vanilla give command to distribute shards another way.
What if a killer is at max and their victim is at min? The victim has nothing to give, so no strength moves — but the max-strength killer still receives the shard drop bounty.
评论 0
登录后参与评分
还没有评论,来抢沙发吧