Structure DFU Cache
通过在磁盘上缓存升级后的结构模板,加速整合包中的世界加载和 /reload。
许多结构和地牢模组附带 .nbt 结构文件,这些文件是在较旧的 Minecraft 版本中保存的,导致原版 DataFixerUpper (DFU) 每次打开世界或运行 /reload 时都必须重新升级完全相同的模板。Structure DFU Cache 将过时的结构模板一次性升级到本地 cache/structure_dfu_cache/ 文件夹,并在后续启动时直接提供升级后的文件。

为什么使用它
- 一次升级,跳过重复工作:自动检测整合包或数据包的变化;当没有变化时,预热世界加载只需几毫秒即可验证缓存,而不是重新转换数千个结构文件。
- 仅处理过时的模板:已经匹配当前 Minecraft 版本(或超出安全大小限制)的结构文件将被保留原样,不会复制占用磁盘空间。
- 对大型整合包友好内存管理:当客户端或服务器堆内存紧张时(
-Xmx <= 6.8G),会自动限制后台工作线程,防止初始缓存构建期间内存激增。 - 内置状态屏幕、OP 命令及聊天就绪通知:可以从 Mod Menu / Forge / NeoForge 配置屏幕或通过
/structuredfucache status和/structuredfucache clear(仅限 OP)检查准备时间、已升级结构数量和缓存磁盘使用情况——或触发完全重建。默认情况下,向加入游戏的 OP 或单人游戏主机发送一条简洁的缓存状态聊天通知(notifyInChat = true;设置为false以静音聊天)。 - 随时添加或移除都安全:与 Lithium、ModernFix、FerriteCore、C2ME 和 LazyDFU 协同工作,且永远不会修改你的世界存档。

配置
在游戏中编辑或在 config/structure_dfu_cache.toml 中编辑:
# 主开关。设置为 false 可绕过缓存并直接加载原始的模组/数据包结构。
enabled = true
# 初始/增量缓存构建期间的最大后台线程数(0 = 根据空闲堆内存自动选择 1..4)。
maxWorkers = 0
# 在 INFO 级别记录详细的缓存构建诊断信息。
verboseLogging = false
# 向加入游戏的 OP / 单人游戏主机发送一条简洁的缓存状态聊天通知(默认开启;设置为 false 以静音聊天)。
notifyInChat = true
Structure DFU Cache
Speeds up world loading and /reload in modpacks by caching upgraded structure templates on disk.
Many structure and dungeon mods ship .nbt structure files saved on older Minecraft versions, forcing vanilla DataFixerUpper (DFU) to re-upgrade the exact same templates every time you open a world or run /reload. Structure DFU Cache upgrades outdated structure templates once into a local cache/structure_dfu_cache/ folder and serves the upgraded files directly on future launches.

Why Use It
- Upgrade once, skip repeat work: Automatically detects modpack or datapack changes; when nothing changed, warm world loads validate the cache in a few milliseconds instead of re-converting thousands of structure files.
- Only touches outdated templates: Structure files that already match the current Minecraft version (or exceed safe size limits) are left untouched without duplicating disk space.
- RAM-friendly on heavy packs: Automatically throttles background worker threads when your client or server runs with tight heap headroom (
-Xmx <= 6.8G) so initial cache builds don't spike memory. - Built-in status screen, OP commands & chat ready notice: Check prepare time, upgraded structure counts, and cache disk usage — or trigger a clean rebuild — from the Mod Menu / Forge / NeoForge config screen or via
/structuredfucache statusand/structuredfucache clear(OPs only). Sends a single concise cache status notice in chat to joining OPs or the singleplayer host by default (notifyInChat = true; setfalsefor silent chat). - Safe to add or remove anytime: Works alongside Lithium, ModernFix, FerriteCore, C2ME, and LazyDFU, and never modifies your world saves.

Configuration
Edit in-game or in config/structure_dfu_cache.toml:
# Master switch. Set false to bypass the cache and load raw mod/datapack structures directly.
enabled = true
# Max background threads during initial/incremental cache builds (0 = automatic 1..4 based on free heap).
maxWorkers = 0
# Log detailed cache build diagnostics at INFO level.
verboseLogging = false
# Send a single concise cache status notice in chat to joining OPs / singleplayer host (on by default; set false for silent chat).
notifyInChat = true
下载 Structure DFU Cache
下载 Structure DFU Cache
下载 Structure DFU Cache
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Structure DFU Cache
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Structure DFU Cache
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Structure DFU Cache
下载 Structure DFU Cache
下载 Structure DFU Cache
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Structure DFU Cache
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Structure DFU Cache
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
- 将
structure_dfu_cache.toml、缺失键回退机制以及游戏内「配置与健康仪表板」界面中的notifyInChat默认值从false改为true(适用于1.20.1、1.21.1和26.x)。加入服务器或单人游戏的玩家现在在每次准备周期中会在聊天栏立即看到一条简洁的缓存摘要;偏好静音聊天的整合包作者可将notifyInChat = false。
- 新增了对 Fabric 和 NeoForge 的 Minecraft 26.3 支持。
- 修复了在 Minecraft 1.20.1 Forge 上缺少
pack.mcmeta(ResourcePackInfo启动警告)的问题。
2.0.2
- 损坏清单自修复:通过安全捕获
MalformedInputException/IOException并自动重建缓存(而非启动崩溃),增强了对非 UTF-8 或二进制损坏的manifest.v2文件的CacheManifest处理。 - 验证与构建工具:添加了本地三重门验证(
./scripts/verify.sh,可选--containerDocker 运行器),覆盖所有 8 个矩阵 JAR、属性测试、ArchitectureContractTest以及打包 JAR NeoForge 1.21.1GameTestServerE2E 测试。
2.0.1
- 修复了在 NeoForge
1.21.1+下,当计算 Jar-in-Jar 嵌套模组的PackFingerprint(包指纹)时发生的启动/世界加载崩溃问题。该问题出现在IModFile.getFilePath()返回虚拟UnionPath(其中toRealPath()返回null并引发跨文件系统ProviderMismatchException/ 属性统计错误)的情况下。 - 增强了对非默认
FileSystem提供者的PackFingerprint路径规范化、相对化及文件元数据统计收集的健壮性。
Structure DFU Cache 2.0.0
- 单层叠加层(
overlay/data/<ns>/<path>)+manifest.v2:用子 5ms 热启动快速路径验证和旧版1.x缓存的自动清理,取代了传统的blobs/、sources/、generations/以及index.json。 - 零依赖的八目标矩阵:涵盖 Fabric 与 Forge(
1.20.1,Java 17)、Fabric 与 NeoForge(1.21.1,Java 21;26.1.2,Java 25;26.2,Java 25),所有文件均小于 100 KB。 - 原生配置与健康仪表盘:内置配置界面(Fabric 上使用 Mod Menu,Forge/NeoForge 上使用原生界面)以及
/structuredfucache status|clear管理员指令。 - 堆安全与进程安全:采用自适应
1–4个工作线程并发,具备prepare.lock机制,并提供四种语言本地化支持(en_us、zh_cn、zh_tw、ja_jp)。
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
评论 0
登录后参与评分
还没有评论,来抢沙发吧