
药水机制
带回声和紫水晶碎片的多步药水升级,隐藏粒子,比较器信号,以及自定义属性药水。
🇬🇧 English
Potion Mechanics
Potion Mechanics extends the vanilla potion system while staying completely data-driven: higher effect levels, longer durations, upgrade ingredients for already brewed potions, particle-free potions, a configurable brewing-stand redstone signal, and fully custom attribute potions such as a Potion of Reach.
The mod registers no new items, blocks, entities or GUIs and uses only vanilla potions, effects and data components. It is fully server-side — players can join without installing anything.
✨ Features
- Effect levels above the vanilla cap, global and per effect (
maxLevelAll,maxLevel). - Effect durations beyond vanilla limits, global and per effect (
maxDurationAll,maxDuration). - Three brewing ingredients that upgrade an already brewed potion step by step.
- A brewing ingredient that hides effect particles while keeping the HUD icon.
- A comparator output mode that pulses when a brewing stand finishes brewing.
- Custom attribute potions defined in JSON, e.g. a Potion of Reach brewed from an Eye of Ender.
/potion reloadand/potion gameruleapply changes instantly and save them to disk.- Works for regular, splash and lingering potions where applicable.
- Server-side only: unmodded clients connect seamlessly.
⚗️ Upgrading Brewed Potions
Vanilla brewing is untouched. Brew a normal potion with normal ingredients up to its vanilla maximum, then improve it further in the brewing stand:
| Default Ingredient | Effect |
|---|---|
| Echo Shard | Raises the potion's level by one step |
| Amethyst Shard | Extends the duration by one step (default +60s) |
| Prismarine Shard / Crystals | Hides the effect particles while keeping the HUD icon |
Each upgrade applies one step per brew. Once the configured limit is reached the stand simply refuses the ingredient instead of consuming it, so materials can never be wasted. Upgrades combine freely: raise the level, extend the time, hide the particles — in any order.
🧪 Custom Attribute Potions
JSON files in config/potionmechanics/attribute_potions/ define potions built from attribute modifiers — for example a Potion of Reach granting extra block and entity interaction range. Each definition picks a vanilla carrier effect purely for the HUD icon and countdown, plus optional brewing recipe.
First launch ships two examples:
- Reach: Awkward Potion + Eye of Ender
- Haste: Awkward Potion + Gold Block
The carrier effect provides the HUD icon only; the real gameplay comes from temporary attribute modifiers applied server-side and removed automatically — including after relog or death.
🚦 Comparator Signal
By default a brewing stand tells a connected comparator about brewing completion instead of fullness: a short pulse when the current potion finishes, zero otherwise. Duration and strength are configurable, and setting mode to vanilla restores the original fullness behaviour.
🛠️ Configuration
config/potionmechanics.json (created automatically, never overwritten):
{
"maxLevelAll": 5,
"maxLevel": {
"minecraft:strength": "-",
"minecraft:speed": 10,
"minecraft:regeneration": 5
},
"maxDurationAll": 960,
"maxDuration": {
"minecraft:strength": 3600,
"minecraft:speed": "-",
"minecraft:regeneration": 1800
},
"levelIngredient": { "enabled": true, "items": ["minecraft:echo_shard"] },
"durationIngredient": { "enabled": true, "items": ["minecraft:amethyst_shard"] },
"noParticlesIngredient": { "enabled": true, "items": ["minecraft:prismarine_shard", "minecraft:prismarine_crystals"] },
"durationStepSeconds": 60,
"comparatorSignal": { "mode": "brew_complete", "pulseTicks": 20, "strength": 15 }
}
"-" means "inherit the global limit". Values outside their valid range are clamped; broken files degrade to defaults with a log warning instead of disabling the mod.
⌨️ Commands
/potion help
/potion reload
/potion gamerule <parameter> [value]
/potion gamerule maxLevel <effect> [value]
/potion gamerule maxDuration <effect> [value]
/potion attribute list
/potion attribute give <potion> [target]
/potion attribute apply <potion> [target]
Every change made through gamerule is applied immediately and written to the JSON file — no restart required. Invalid values, unknown parameters, unknown effects and unknown items are rejected with a clear message. Brigadier autocompletion works throughout.
🧩 Compatibility & Technical Notes
Install on the server only; clients need nothing. Levels, durations and hidden particles travel through standard effect packets and data components, so an unmodded client renders everything correctly.
Available for Fabric 1.19.2 - 1.21.11, Forge 1.19.2 - 1.21.11, and NeoForge 1.21.1.
🇷🇺 Русский
Potion Mechanics
Potion Mechanics 在保持完全数据驱动的同时扩展了原版药水系统:更高的效果等级、更长的持续时间、用于升级已酿造药水的升级材料、无颗粒药水、可配置的酿造台红石信号,以及完全自定义的属性药水,例如触及距离药水。
该模组不注册任何新物品、方块、实体或 GUI,仅使用原版药水、效果和数据组件。它完全在服务端运行——玩家无需安装任何内容即可加入。
✨ 特性
- 效果等级可超过原版上限,支持全局和按效果配置(
maxLevelAll、maxLevel)。 - 效果持续时间可超过原版限制,支持全局和按效果配置(
maxDurationAll、maxDuration)。 - 三种酿造材料,可逐步升级已酿造的药水。
- 一种酿造材料,可隐藏效果颗粒,同时保留 HUD 图标。
- 一种比较器输出模式,在酿造台完成酿造时发出脉冲。
- 在 JSON 中定义的自定义属性药水,例如用末影之眼酿造而成的触及距离药水。
/potion reload和/potion gamerule可立即应用更改并保存到磁盘。- 在适用的情况下,适用于普通、喷溅和滞留药水。
- 仅服务端:未安装模组的客户端可无缝连接。
⚗️ 升级已酿造的药水
原版酿造不受影响。先用普通材料将普通药水酿造到原版上限,然后在酿造台中进一步升级:
| 默认材料 | 效果 |
|---|---|
| 回响碎片 | 将药水等级提升一级 |
| 紫水晶碎片 | 将持续时间延长一级(默认 +60 秒) |
| 海晶碎片 / 海晶砂粒 | 隐藏效果颗粒,同时保留 HUD 图标 |
每次酿造应用一级升级。一旦达到配置的上限,酿造台会直接拒绝该材料而不是消耗它,因此材料绝不会被浪费。升级可自由组合:提升等级、延长时间、隐藏颗粒——顺序不限。
🧪 自定义属性药水
config/potionmechanics/attribute_potions/ 中的 JSON 文件定义了基于属性修饰符构建的药水——例如赋予额外方块和实体交互距离的触及距离药水。每个定义会选择一个原版载体效果,仅用于 HUD 图标和倒计时,外加可选的酿造配方。
首次启动会附带两个示例:
- 触及距离: 粗制的药水 + 末影之眼
- 急迫: 粗制的药水 + 金块
载体效果仅提供 HUD 图标;实际游戏效果来自服务端应用的临时属性修饰符,并会自动移除——包括在重新登录或死亡之后。
🚦 比较器信号
默认情况下,酿造台告知连接的比较器的是酿造完成而非装满程度:当前药水完成时发出短脉冲,否则为零。持续时间和强度可配置,将模式设置为 vanilla 可恢复原本的装满程度行为。
🛠️ 配置
config/potionmechanics.json(自动创建,从不覆盖):
{
"maxLevelAll": 5,
"maxLevel": {
"minecraft:strength": "-",
"minecraft:speed": 10,
"minecraft:regeneration": 5
},
"maxDurationAll": 960,
"maxDuration": {
"minecraft:strength": 3600,
"minecraft:speed": "-",
"minecraft:regeneration": 1800
},
"levelIngredient": { "enabled": true, "items": ["minecraft:echo_shard"] },
"durationIngredient": { "enabled": true, "items": ["minecraft:amethyst_shard"] },
"noParticlesIngredient": { "enabled": true, "items": ["minecraft:prismarine_shard", "minecraft:prismarine_crystals"] },
"durationStepSeconds": 60,
"comparatorSignal": { "mode": "brew_complete", "pulseTicks": 20, "strength": 15 }
}
"-" 表示“继承全局限制”。超出有效范围的值会被钳制;损坏的文件会降级为默认值并记录日志警告,而不会禁用模组。
⌨️ 命令
/potion help
/potion reload
/potion gamerule <参数> [值]
/potion gamerule maxLevel <效果> [值]
/potion gamerule maxDuration <效果> [值]
/potion attribute list
/potion attribute give <药水> [目标]
/potion attribute apply <药水> [目标]
通过 gamerule 所做的每一项更改都会立即应用并写入 JSON 文件——无需重启。无效值、未知参数、未知效果和未知物品都会被拒绝并给出明确提示。全程支持 Brigadier 自动补全。
🧩 兼容性与技术说明
仅需安装在服务端;客户端无需任何内容。等级、持续时间和隐藏的颗粒通过标准效果数据包和数据组件传输,因此未安装模组的客户端也能正确渲染一切。
适用于 Fabric 1.19.2 - 1.21.11、Forge 1.19.2 - 1.21.11 和 NeoForge 1.21.1。
正在加载版本记录…
正在加载评论…
评论在新手盒子客户端中发表,这里同步展示。