Breakableblocks
Breakableblocks 是一个服务端 Fabric 模组,它使通常无法破坏或受限的方块可以通过精确的计时、工具要求、自定义掉落和防爆保护进行挖掘。它通过服务器上的单个 JSON5 文件进行配置。原版客户端无需安装任何内容即可加入服务器。
服务器管理员使用它可以开放基岩、屏障、命令方块、传送门方块、刷怪笼、试炼刷怪笼、宝库、末地传送门、加固深板岩以及任何其他已注册方块 ID 的进度,同时完全控制每个方块的挖掘时间和掉落物。
模组功能
- 使配置的方块可通过服务器权威采矿会话进行破坏。
- 在每个服务器刻追踪采矿进度,并显示正常的方块碎裂动画。
- 在动作栏中显示带有百分比、文本栏和剩余秒数的进度条。
- 在开始挖掘之前需要特定的工具、材料等级和精准采集附魔。
- 计时结束后,用配置的物品和数量替换原版掉落物。
- 可选地在掉落的物品上保留受支持的方块实体数据。
- 通过在销毁前过滤配置的方块,保护它们免受爆炸影响。
- 可选地将敏感方块限制为仅服务器操作员可挖掘。
- 当玩家停止挖掘、断开连接、切换维度、移动过远或方块发生变化时,安全取消采矿。
- 无需重启服务器即可重新加载配置。
自定义采矿仅适用于配置中列出的方块。所有其他方块使用正常的原版行为。
安装
- 对于 Minecraft 1.21.11,安装 Fabric Loader 0.19.3 或更高版本;对于 26.1 和 26.2,安装 0.19.3+;对于 26.3,安装 0.19.5+。
- 安装匹配的 Fabric API 版本。
- 下载与你的 Minecraft 版本匹配的 Breakableblocks 文件:
- 1.21.11:需要 Java 21
- 26.1, 26.1.1, 26.1.2:需要 Java 25
- 26.2:需要 Java 25
- 26.3:需要 Java 25
- 将 JAR 文件放入服务器的
mods 文件夹中。该模组仅需安装在服务器上。
- 启动服务器一次以生成
config/block-configuration.json5。
- 编辑该文件,然后在游戏中运行
/blockconfiguration reload 或重启服务器。
玩家无需安装客户端模组、资源包或进行额外设置。
配置
配置文件创建位置如下:
config/block-configuration.json5
每个顶级键都是命名空间化的方块 ID。该文件支持注释和尾随逗号。
简单示例:
{
"minecraft:bedrock": {
"breakSeconds": 30,
"tool": "netherite_pickaxe",
"drop": "minecraft:bedrock x1",
"blastResistant": true
},
"minecraft:spawner": {
"breakSeconds": 15,
"tool": "netherite_pickaxe",
"drop": "minecraft:spawner x1",
"preserveBlockEntity": true,
"blastResistant": true
},
"minecraft:command_block": {
"breakSeconds": 5,
"tool": "netherite_pickaxe",
"drop": "minecraft:command_block x1",
"blastResistant": true,
"operatorOnly": true
}
}
简单字段
| 字段 |
类型 |
描述 |
breakSeconds |
Number |
挖掘时间(秒)。20 个刻等于 1 秒。自动设置为 FIXED_TICKS 模式。 |
tool |
String |
工具要求,单个值,例如 netherite_pickaxe、diamond_pickaxe、iron_axe,或使用 any 表示无要求。 |
drop |
String |
掉落物,单个值,例如 minecraft:bedrock x1 或 minecraft:torch x4。使用计数 0 或空值表示无掉落。 |
blastResistant |
Boolean |
如果为 true,爆炸不会摧毁该方块。是 explosionResistant 的简单别名。 |
operatorOnly |
Boolean |
如果为 true,只有服务器操作员可以挖掘该方块。是 protectionBehavior: OPERATOR_ONLY 的简单别名。 |
requireSilkTouch |
Boolean |
如果为 true,手持工具必须具有精准采集附魔。 |
preserveBlockEntity |
Boolean |
如果为 true,受支持的方块实体数据将被复制到掉落的物品中。在生产环境使用前请测试携带数据的方块。 |
enabled |
Boolean |
如果为 false,则忽略该条目。默认为 true。 |
高级字段
为了向后兼容和精细控制,仍支持高级字段。
| 字段 |
类型 |
描述 |
miningMode |
String |
VANILLA 用于正常破坏,FIXED_TICKS 用于配置时长,CUSTOM_HARDNESS 用于基于硬度的时长。 |
fixedTicks |
Integer |
FIXED_TICKS 模式的精确持续时间(服务器刻)。必须大于零。如果为空,breakSeconds 会自动填充此值。 |
customHardness |
Number |
仅在 CUSTOM_HARDNESS 模式下使用的硬度值。 |
requiredTool |
String |
工具类别:pickaxe、axe、shovel 或 hoe。空值表示任意工具。 |
requiredTier |
String |
最低等级:wood、stone、gold、iron、diamond 或 netherite。空值表示无等级要求。 |
dropItem |
String |
配置掉落物的命名空间物品 ID。空值表示无配置掉落物。 |
dropCount |
Integer |
掉落数量,范围从 0 到 2304。大数量会拆分为多个堆栈。 |
explosionResistant |
Boolean |
如果为 true,爆炸不会摧毁该方块。如果在旧版配置中省略了该字段,则默认为 true。 |
protectionBehavior |
String |
NORMAL 允许所有人,OPERATOR_ONLY 仅限操作员。 |
failureFeedback |
String |
ACTION_BAR 用于动作栏消息,CHAT 用于聊天消息,NONE 隐藏要求消息和采矿进度。 |
placementBehavior |
String |
为保护集成保留。正常游戏使用 NORMAL。 |
注意:
dropItem、dropCount 和方块实体保留仅适用于自定义采矿会话。留在 VANILLA 模式的方块保持正常的战利品行为。
- 无效条目将被跳过并记录日志。如果文件无法解析,之前的有效配置将保持活动状态。
- 方块和物品 ID 必须使用完整的
namespace:path 格式。
- 计时器使用服务器刻。严重的延迟可能导致实际完成时间变长。
命令
所有命令均使用基础命令 /blockconfiguration。
| 命令 |
说明 |
/blockconfiguration |
显示所有子命令的帮助信息。 |
/blockconfiguration help |
显示所有子命令的帮助信息。 |
/blockconfiguration list |
列出所有当前生效的方块规则,包括时间、工具要求和掉落汇总。 |
/blockconfiguration inspect <block> |
显示指定方块 ID 的当前设置,例如 /blockconfiguration inspect minecraft:bedrock。 |
/blockconfiguration reload |
在不重启服务器的情况下重新加载并验证 config/block-configuration.json5。报告有多少个方块处于激活状态。 |
/blockconfiguration validate |
报告当前有多少个有效且已启用的条目处于激活状态。 |
命令中的方块 ID 必须包含命名空间,例如 minecraft:bedrock。
服务器行为
- 目标方块仍必须与启动该会话的方块匹配。
- 玩家必须保持存活、在线、处于同一维度,并且距离在 8 格以内。
- 释放或中止挖掘操作会取消会话。
- 切换目标会清除之前的破碎动画。
- 掉落物仅在完整持续时间结束后才在服务器上生成。
- 爆炸保护位置会在爆炸摧毁方块之前被移除。
- 仅限操作员使用的方块会在开始工具检查之前进行校验。
版本支持
| 模组文件 |
Minecraft |
Java |
加载器 |
Fabric API |
| 1.0.0+1.21.11 |
1.21.11 |
21 |
0.19.3+ |
0.141.5+1.21.11 |
| 1.0.0+26.1 |
26.1, 26.1.1, 26.1.2 |
25 |
0.19.3+ |
0.145.1+26.1 |
| 1.0.0+26.2 |
26.2 |
25 |
0.19.3+ |
0.155.2+26.2 |
| 1.0.0+26.3 |
26.3 |
25 |
0.19.5+ |
0.161.0+26.3 |
服务器需要安装 Fabric API。客户端不需要此模组。
许可证
保留所有权利。
Breakableblocks
Breakableblocks is a server-side Fabric mod that makes normally unbreakable or restricted blocks mineable with exact timings, tool requirements, custom drops, and explosion protection. It is configured through a single JSON5 file on the server. Vanilla clients can join without installing anything.
Server owners use it to open up progression on bedrock, barriers, command blocks, portal blocks, spawners, trial spawners, vaults, end gateways, reinforced deepslate, and any other registered block ID, while keeping full control over how long each block takes and what it drops.
What the mod does
- Makes configured blocks breakable with server-authoritative mining sessions.
- Tracks mining progress every server tick and shows the normal block-cracking animation.
- Shows an action-bar progress bar with percent, a text bar, and seconds remaining.
- Requires specific tools, material tiers, and Silk Touch before mining can start.
- Replaces vanilla drops with a configured item and count after the timer completes.
- Optionally preserves supported block entity data on the dropped item.
- Protects configured blocks from explosions by filtering them before destruction.
- Optionally restricts sensitive blocks to server operators.
- Cancels safely when the player stops mining, disconnects, changes dimension, moves too far away, or the block changes.
- Reloads configuration without restarting the server.
Custom mining only applies to blocks listed in the config. All other blocks use normal vanilla behavior.
Installation
- Install Fabric Loader 0.19.3 or newer for Minecraft 1.21.11, or 0.19.3+ for 26.1 and 26.2, or 0.19.5+ for 26.3.
- Install the matching Fabric API version.
- Download the Breakableblocks file that matches your Minecraft version:
- 1.21.11: Java 21 required
- 26.1, 26.1.1, 26.1.2: Java 25 required
- 26.2: Java 25 required
- 26.3: Java 25 required
- Place the JAR in the server
mods folder. The mod is only required on the server.
- Start the server once to generate
config/block-configuration.json5.
- Edit the file, then run
/blockconfiguration reload in game or restart the server.
No client mod, resource pack, or extra setup is needed for players.
Configuration
The config file is created at:
config/block-configuration.json5
Each top-level key is a namespaced block ID. The file supports comments and trailing commas.
Simple example:
{
"minecraft:bedrock": {
"breakSeconds": 30,
"tool": "netherite_pickaxe",
"drop": "minecraft:bedrock x1",
"blastResistant": true
},
"minecraft:spawner": {
"breakSeconds": 15,
"tool": "netherite_pickaxe",
"drop": "minecraft:spawner x1",
"preserveBlockEntity": true,
"blastResistant": true
},
"minecraft:command_block": {
"breakSeconds": 5,
"tool": "netherite_pickaxe",
"drop": "minecraft:command_block x1",
"blastResistant": true,
"operatorOnly": true
}
}
Simple fields
| Field |
Type |
Description |
breakSeconds |
Number |
Mining time in seconds. 20 ticks equals 1 second. Sets FIXED_TICKS mode automatically. |
tool |
String |
Tool requirement in one value, for example netherite_pickaxe, diamond_pickaxe, iron_axe, or any for no requirement. |
drop |
String |
Drop in one value, for example minecraft:bedrock x1 or minecraft:torch x4. Use count 0 or an empty value for no drop. |
blastResistant |
Boolean |
If true, explosions do not destroy the block. Simple alias for explosionResistant. |
operatorOnly |
Boolean |
If true, only server operators can mine the block. Simple alias for protectionBehavior: OPERATOR_ONLY. |
requireSilkTouch |
Boolean |
If true, the held tool must have Silk Touch. |
preserveBlockEntity |
Boolean |
If true, supported block entity data is copied to the dropped item. Test data-bearing blocks before production use. |
enabled |
Boolean |
If false, the entry is ignored. Default is true. |
Advanced fields
Advanced fields are still supported for backwards compatibility and fine control.
| Field |
Type |
Description |
miningMode |
String |
VANILLA for normal breaking, FIXED_TICKS for configured duration, CUSTOM_HARDNESS for hardness-derived duration. |
fixedTicks |
Integer |
Exact duration in server ticks for FIXED_TICKS. Must be greater than zero. breakSeconds fills this automatically when empty. |
customHardness |
Number |
Hardness value used only with CUSTOM_HARDNESS mode. |
requiredTool |
String |
Tool family: pickaxe, axe, shovel, or hoe. Empty means any tool. |
requiredTier |
String |
Minimum tier: wood, stone, gold, iron, diamond, or netherite. Empty means no tier requirement. |
dropItem |
String |
Namespaced item ID for the configured drop. Empty means no configured drop. |
dropCount |
Integer |
Drop amount from 0 to 2304. Large counts are split into multiple stacks. |
explosionResistant |
Boolean |
If true, explosions do not destroy the block. Default is true when the field is omitted in older configs. |
protectionBehavior |
String |
NORMAL for everyone, OPERATOR_ONLY for operators only. |
failureFeedback |
String |
ACTION_BAR for action-bar messages, CHAT for chat messages, NONE to hide requirement messages and mining progress. |
placementBehavior |
String |
Reserved for protection integrations. Normal gameplay uses NORMAL. |
Notes:
dropItem, dropCount, and block entity preservation apply to custom mining sessions. Blocks left on VANILLA keep normal loot behavior.
- Invalid entries are skipped and logged. If the file cannot be parsed, the previous valid configuration stays active.
- Block and item IDs must use the full
namespace:path format.
- Timers use server ticks. Heavy lag can make real-world completion time longer.
Commands
All commands use the base /blockconfiguration.
| Command |
Description |
/blockconfiguration |
Shows help with all subcommands. |
/blockconfiguration help |
Shows help with all subcommands. |
/blockconfiguration list |
Lists every active block rule with time, tool requirement, and drop summary. |
/blockconfiguration inspect <block> |
Shows the active settings for one exact block ID, for example /blockconfiguration inspect minecraft:bedrock. |
/blockconfiguration reload |
Reloads and validates config/block-configuration.json5 without restarting. Reports how many blocks are active. |
/blockconfiguration validate |
Reports how many valid and enabled entries are currently active. |
Block IDs in commands must include the namespace, for example minecraft:bedrock.
Server behavior
- The target block must still match the block that started the session.
- The player must stay alive, connected, in the same dimension, and within 8 blocks.
- Releasing or aborting the mining action cancels the session.
- Switching targets clears the previous cracking animation.
- Drops spawn on the server only after the full duration completes.
- Explosion-protected positions are removed before the explosion destroys blocks.
- Operator-only blocks are checked before tool checks begin.
Version support
| Mod file |
Minecraft |
Java |
Loader |
Fabric API |
| 1.0.0+1.21.11 |
1.21.11 |
21 |
0.19.3+ |
0.141.5+1.21.11 |
| 1.0.0+26.1 |
26.1, 26.1.1, 26.1.2 |
25 |
0.19.3+ |
0.145.1+26.1 |
| 1.0.0+26.2 |
26.2 |
25 |
0.19.3+ |
0.155.2+26.2 |
| 1.0.0+26.3 |
26.3 |
25 |
0.19.5+ |
0.161.0+26.3 |
Fabric API is required on the server. Clients do not need the mod.
License
All Rights Reserved.
评论 0
登录后参与评分
还没有评论,来抢沙发吧