TheFloydman / More-Mystcraft

Other
2 stars 1 forks source link

Disabling Both Block and Recipe Breaks Non-JSON Recipes #28

Closed Nimbleguy closed 4 years ago

Nimbleguy commented 4 years ago

What version of More Mystcraft are you using? 0.8.5

What version of Mystcraft are you using? 0.13.7.04

What version of Forge are you using? 14.23.5.2847

What version of Minecraft are you using? 1.12.2

What modpack and modpack version are you using, if any? My own

Does the bug occur server-side, client-side, or both? Both

Paste a link to your log or crash report here. Use a service like pastebin. No images, please. https://hatebin.com/rzqczzyykg (too long for pastebin)

Describe the bug When disabling both a block and its recipe (note that this does not happen when just disabling the recipe), all recipes from either vanilla or other mods that abstract over their inputs break, such as combining tools to repair durability, or adding books to an Akashic Tome.

To Reproduce Steps to reproduce the behavior:

  1. Disable the Unstable Receptacle and its recipe in the MoreMystcraft config
  2. Try to repair tools by crafting them together

Expected behavior The recipes to work.

Additional context It seems to be caused due to, when a block is disabled, its ItemBlock is not registered in MoreMystcraftBlocks, leading to the item field in the Recipes enum in CraftingHandler becoming null, when then in CraftingHandler#handleRecipe leads to the recipe being replaced with a DummyRecipe. In the broken recipes, IRecipe#getRecipeOutput returns null, which equals Item#getItemFromBlock when the block does not have a registered ItemBlock.

In the log, one may notice that every broken recipe gets registered under moremystcraft, with Forge pointing out the original mod as a potentially dangerous alternative prefix (https://pastebin.com/bDnmSxpz).

TheFloydman commented 4 years ago

Fixed in most recent release (0.8.6).