diff options
author | Vanessa Ezekowitz <vanessaezekowitz@gmail.com> | 2017-06-13 00:17:52 -0400 |
---|---|---|
committer | Vanessa Ezekowitz <vanessaezekowitz@gmail.com> | 2017-06-13 00:17:52 -0400 |
commit | db480011fbc77b3c2249e0cf3dcae1ae9087784f (patch) | |
tree | f33131fc9d403d002c5cabf615ba299fb5f717c6 | |
parent | 4cc124ff9e31f722433d999aa8efe555b1f4425e (diff) |
only try to clear/redefine recipes for teleport and accel tube
if they are enabled in pipeworks' config
-rw-r--r-- | technic/crafts.lua | 48 |
1 files changed, 26 insertions, 22 deletions
diff --git a/technic/crafts.lua b/technic/crafts.lua index 9e07978..14bafd3 100644 --- a/technic/crafts.lua +++ b/technic/crafts.lua @@ -9,34 +9,38 @@ minetest.clear_craft({ }) -- Accelerator tube -minetest.clear_craft({ - output = "pipeworks:accelerator_tube_1", -}) +if pipeworks.enable_accelerator_tube then + minetest.clear_craft({ + output = "pipeworks:accelerator_tube_1", + }) + + minetest.register_craft({ + output = 'pipeworks:accelerator_tube_1', + recipe = { + {'technic:copper_coil', 'pipeworks:tube_1', 'technic:copper_coil'}, + } + }) +end -- Teleport tube -minetest.clear_craft({ - output = "pipeworks:teleport_tube_1", -}) +if pipeworks.enable_teleport_tube then + minetest.clear_craft({ + output = "pipeworks:teleport_tube_1", + }) + + minetest.register_craft({ + output = 'pipeworks:teleport_tube_1', + recipe = { + {'default:mese_crystal', 'technic:copper_coil', 'default:mese_crystal'}, + {'pipeworks:tube_1', 'technic:control_logic_unit', 'pipeworks:tube_1'}, + {'default:mese_crystal', 'technic:copper_coil', 'default:mese_crystal'}, + } + }) +end -- tubes crafting recipes minetest.register_craft({ - output = 'pipeworks:accelerator_tube_1', - recipe = { - {'technic:copper_coil', 'pipeworks:tube_1', 'technic:copper_coil'}, - } -}) - -minetest.register_craft({ - output = 'pipeworks:teleport_tube_1', - recipe = { - {'default:mese_crystal', 'technic:copper_coil', 'default:mese_crystal'}, - {'pipeworks:tube_1', 'technic:control_logic_unit', 'pipeworks:tube_1'}, - {'default:mese_crystal', 'technic:copper_coil', 'default:mese_crystal'}, - } -}) - -minetest.register_craft({ output = 'technic:diamond_drill_head', recipe = { {'technic:stainless_steel_ingot', 'default:diamond', 'technic:stainless_steel_ingot'}, |