KubeJS

KubeJS

61M Downloads

KubeJS breaks recipes from Tinkerer's Smithing

mintynoura opened this issue ยท 1 comments

commented

Minecraft Version

Quilt 1.20.1

KubeJS Version

kubejs-fabric-2001.6.4-build.138

Rhino Version

rhino-fabric-2001.2.2-build.18

Architectury Version

architectury-9.1.12-fabric

Forge/Fabric Version

Quilt 0.25.0

Describe your issue

It seems that using startup scripts from KubeJS to modify or register anything (not necessarily related to anvils/smithing) will disable all the crafting and smithing recipes from Tinkerer's Smithing, as well as the vanilla anvil repairing mechanics. The developers of Tinkerer's Smithing responded here explaining that the issue can't be fixed on their side, so I'm reporting it here. The Minecraft/KubeJS logs don't seem to mention anything related to the problem.

323741601-f4aeed8d-2911-4a9d-a501-bf90cb937c71

323742263-8dd5da10-53e8-4949-a344-1b6577d87445

Crash report/logs

N/A

commented

It's unlikely that KubeJS will change those mixins, but if the mod author wants to/someone wants to PR it then they can make a KubeJS plugin to register their java generated recipes.

/**
* Only use this method if your mod adds runtime recipes and is conflicting with KubeJS recipe manager. Disable your other hook if "kubejs" mod is loaded!
*/
public void injectRuntimeRecipes(RecipesEventJS event, RecipeManager manager, Map<ResourceLocation, Recipe<?>> recipesByName) {
}

The steps for doing this are:

  • Make a class that extends KubeJSPlugin
  • Override injectRuntimeRecipes and add your recipes there
  • Cancel your normal recipe adding if KubeJS is installed (though that seems like it is already happening here)
  • Add a kubejs.plugins.txt to the root of your jar (the resources folder) that contains a single line of the full classpath of your KubeJS plugin, ie mods.chiefarug.moddymcmodface.compat.kubejs.ModdyKubeJSPlugin