准备好找出罪魁祸首了吗?
Forge 版本:
Blame 是一款诊断工具,仅在你遇到奇怪的生物群系生成崩溃或命令无堆栈跟踪而中断时才应启用。但当你开启 Blame 时,它会尝试收集更多信息并将堆栈跟踪打印到 mods 文件夹上方的 logs 文件夹中的 latest.log 文件中。这是一个包含所有所需信息的更便捷位置!请注意,Blame 仅在单人游戏或服务器上有效。不适用于连接到服务器的客户端。
注意:为了在 1.17+ 中获得更好的生物群系生成 JSON 解析帮助,请使用 Cyanide 模组:
以下是 Blame 目前具备的功能列表!
• 打印在使用时崩溃的命令的堆栈跟踪。
(通常,模组化的命令在崩溃时不会向日志输出任何内容)
• 将在世界启动时检测并打印出所有损坏的命令。
(这将找到那些在 .then() 调用之外调用 .executes() 的命令,因为它们无法正常工作)
• 打印生物群系生成期间崩溃的特性或结构的额外详细信息。
• 记录所有未注册的 ConfiguredFeatures、ConfiguredStructures 和 ConfiguredCarvers。
(未注册这些内容的模组会导致其他模组的内容在生物群系生成期间损坏且不生成)
• 检测 DynamicRegistry 是否被其他模组过早加载。
(这样做会导致其他模组注册的所有生物群系生成内容出错,例如“未知生物群系 ID”问题)
• 记录来自任何模组或数据包的哪个生物群系生成 JSON 文件已损坏,并显示其 JSON 内容。
• 当尝试生成战利品时,记录任何缺失的战利品表!如果箱子为空,请检查日志,此模组可能会捕获原因。
• 压缩损坏的配方和战利品表解析,以便更容易共享日志并查看错误。
• 修复 MC-190122 错误,使日志中实际加载和声明的配方数量正确,以帮助调试配方。
• 打印出间距值设置为 0 或其分离值大于或等于间距值的崩溃结构的名称。
(这两个条件中的任何一个为真都会导致游戏崩溃。)
• 精确打印出哪个结构因未添加到 FlatGenerationSettings.STRUCTURES 而导致自定义/平坦 ChunkGenerator 崩溃。
• 如果 Jigsaw Structure 尝试访问不存在的模板池,将打印到日志,以便你知道结构未完全生成。
• 如果模组或数据包尝试访问不存在的 nbt 文件,将记录日志以便更容易调试。
• 将打印出在结构生成期间导致结构处理器崩溃的方块及其 nbt 数据。
对于模组开发者:在 Fabric 开发环境中使用 Blame
在你的 build.gradle 文件中,添加此 maven 仓库。这是 gradle 查找 Blame jar 包的位置。
repositories {
maven {
url ""
}
}
现在将此添加到依赖块中。将 <version> 替换为你想要使用的 Blame 版本,例如 `1.16.5-3.2.0-fabric`。查看 CurseForge 页面以获取最新版本。
dependencies {
...
modImplementation "com.telepathicgrunt:Blame-Fabric:1.16.5-3.0.1-fabric"
}
启动游戏,Blame 应该正在运行!你可以通过 Blame 向 IDE 控制台和 latest.log 文件打印类似以下内容来确认:
[18:25:48] [main/ERROR] (Blame) Blame 1.16.5-3.0.1-fabric initialized
我的模组 Discord #telepathicgrunt-mods 频道链接:
Ready to find who to Blame?
Forge version:
Blame is a diagnostics tool to be put on only if you are having strange worldgen crashes or commands that break without any stacktrace. But when you have Blame on, it will attempt to gather far more infomation and print the stacktrace to the latest.log file in the logs folder above the mods folder. A much more convenient place with all the info you will need! Keep in mind, Blame only works on singleplayer or on servers. Not on clients connecting to a server.
Note: for better worldgen json parsing help in 1.17+, use Cyanide mod instead:
Here's the current list of functionalities that Blame has!
• Prints out the stacktrace for commands that crashed when used.
(Normally, modded commands do not print anything to logs when they crash)
• Will detect and print out all broken commands when starting up a world.
(This will find commands that called an .executes() outside a .then() call because they won't work)
• Prints extra detail for features or structures that crashes during worldgen.
• Logs all ConfiguredFeatures, ConfiguredStructures, ConfiguredCarvers that are not registered.
(Mods that don't register the stuff will cause other mod's stuff to break and not spawn during worldgen)
• Detect if DynamicRegistry is loaded way too early by another mod.
(Doing so causes all other mod's registered worldgen stuff to blow up such as "Unknown Biome ID" issues)
• Logs out exactly which worldgen JSON file is broken from any mod or datapack and shows its JSON too.
• Logs out any missing loot table when the loot is attempted to be generated! Check logs if a chest is empty and this mod might catch why.
• Condense broken Recipe and Loot Table parsing so you can share logs easier and see errors easier.
• Fixes MC-190122 bug so that the actual true number of recipes loaded and stated in logs is correct to help debugging recipes.
• Prints out the name of the crashing structure that has its spacing value set to 0 or if it's separation value is equal to or greater than the spacing value.
(Either one of these condition being true will crash the game.)
• Prints out exactly which structure crashed a custom/flat ChunkGenerator because it wasn't added to FlatGenerationSettings.STRUCTURES
• Will print to logs if a Jigsaw Structure attempts to access a non-existent template pool so you know when a structure is not fully generating.
• Will log out if a mod or datapack tries to access a non-existent nbt file for easier debugging.
• Will print out what block and its nbt crashed a structure processor during structure generation.
FOR MODDERS: USING BLAME IN Fabric DEV ENVIRONMENT
In your build.gradle file, add this maven repository. This is where gradle will look for Blame's jar.
repositories {
maven {
url ""
}
}
Now add this to the dependency block. Replace <version> with the Blame version you want to use such as `1.16.5-3.2.0-fabric`. Check the CurseForge page for what the latest version is.
dependencies {
...
modImplementation "com.telepathicgrunt:Blame-Fabric:1.16.5-3.0.1-fabric"
}
Launch the game and Blame should be running! You can tell as Blame will print something like this to the IDE console and latest.log file:
[18:25:48] [main/ERROR] (Blame) Blame 1.16.5-3.0.1-fabric initialized
Discord Link to #telepathicgrunt-mods channel for my mods! :
下载 Blame (Fabric)
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Blame (Fabric)
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Blame (Fabric)
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Blame (Fabric)
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Blame (Fabric)
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Blame (Fabric)
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Blame (Fabric)
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Blame (Fabric)
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Blame (Fabric)
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Blame (Fabric)
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
(V.4.3.2 更新内容) (1.17.1 Minecraft)
模组兼容:
修复了 Notify 的兼容性问题
(V.4.3.1 更新内容) (1.17.1 Minecraft)
模组兼容:
新增对 Notify 的支持 - Notify 会在 Blame 发布新更新时通知你。
(V.4.3.0 更新内容) (1.17.1 Minecraft)
空处理器 (Null Processors):
现在会输出因处理器列表为空而导致崩溃的池(pool)信息。
无效玩家数据 (Invalid Player Data):
当遇到因无效玩家数据导致的断开连接时,现在会输出原本会被隐藏到日志中的错误消息。
(V.4.2.0 更新内容) (1.17.1 Minecraft)
结构注册 (Structure Registration):
修复了报告名称错误的问题 lol。并优化了 Structure.STRUCTURES_REGISTRY 字段的报告格式,使其更加清晰。
世界生成生物刷怪 (Worldgen Mob Spawning):
如果游戏因在世界生成期间某生物的 minGroup size 大于其 maxGroup size 而即将崩溃,将检测并输出相关信息。
(V.4.1.0 更新内容) (1.17.1 Minecraft)
结构注册 (Structure Registration):
如果已注册的结构未同时添加到 StructureFeature.STRUCTURES 字段 (Yarn),现在将输出一份 Blame 报告。 任何不在该字段中的结构都会导致区块无法保存,这很糟糕。而且针对该问题的错误提示非常模糊。
结构组件 NBT (Structure Piece NBT):
现在将尝试输出在保存结构引用到区块时,哪些结构组件未能转换为 NBT。
未注册的世界生成 (Unregistered Worldgen):
精简了报告,使影响所有生物群系的未注册世界生成情况显示为“所有生物群系”,而不是列出每个生物群系。
(V.4.0.1 更新内容) (1.17.1 Minecraft)
损坏/未注册的世界生成 (Broken/Unregistered Worldgen):
修复了对损坏的 ConfiguredFeatures 的检测,使其现在能够被正确报告。 例如,给树干的播放器 codec 赋予过大的值,现在会被报告出来,因为这可能在解析过程中破坏其他 ConfiguredFeatures。
移除了对未注册世界生成的检测,因为我在 1.17 版本中无法使其正常工作,而且 Fabric API 应该强制要求人们进行注册。
导致崩溃的 ConfiguredStructure/ConfiguredFeatures
修复了未注册的 ConfiguredFeatures 未在报告中转储其 JSON 文件的问题。
杂项 (Misc):
移除了一些不再需要且现已无用的 mixins
调整了 Blame 报告的标题以标明其主题,方便通过 ctrl+f 搜索来查找特定报告
(V.4.0.0 更新内容) (1.17.0 Minecraft)
杂项 (Misc):
移植至 1.17.0 MC
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
模组
一个基于构建器的 Minecraft 配置库!
模组
? 使用命令保存和加载玩家或他人的背包/套装。
模组
一款轻量级模组,允许服务器管理员对抗透视作弊者。
模组
恢复所有账户的游戏聊天访问权限
模组
通过图形界面控制模组加载。适用于需要可选功能的整合包和服务器,也适合不想手动操作文件而希望直接管理模组的极客用户。
模组
实体tick优化
评论 0
登录后参与评分
还没有评论,来抢沙发吧