From e879f588b686b0bbfbd4f4faa81475fe41f93ba9 Mon Sep 17 00:00:00 2001 From: Handful of Frogs Date: Fri, 10 May 2024 22:37:19 +0300 Subject: [PATCH] feat: macerator craft guide example --- api.lua | 8 ++++++++ compatibility.lua | 6 ++++++ 2 files changed, 14 insertions(+) diff --git a/api.lua b/api.lua index ca21cd3..c53a4d8 100644 --- a/api.lua +++ b/api.lua @@ -749,6 +749,14 @@ industrialtest.api.registerMaceratorRecipe=function(config) recipe=config.recipe or "", time=config.time or 2 } + if mcl_craftguide ~= nil then + mcl_craftguide.register_craft({ + type = "industrialtest.macerating", + width = 1, + output = definition.output, + items = {definition.recipe} + }) + end industrialtest.api.maceratorRecipes[definition.recipe]=definition end -- \brief Returns macerator recipe result diff --git a/compatibility.lua b/compatibility.lua index cc3f681..8142bbd 100644 --- a/compatibility.lua +++ b/compatibility.lua @@ -610,6 +610,12 @@ if industrialtest.mclAvailable then y_max=mcl_worlds.layer_to_y(16), y_min=mcl_vars.mg_overworld_min }) + + mcl_craftguide.register_craft_type("industrialtest.macerating", { + description = S("Macerating"), + icon = "industrialtest_machine_block.png^industrialtest_macerator_front_active.png" + }) + elseif industrialtest.mtgAvailable then industrialtest.internal.explode=function(pos,radius) tnt.boom(pos,{radius=radius})