Replace digiline wires with digimese if digistuff is enabled

This commit is contained in:
SX 2020-04-28 09:56:28 +03:00 committed by Buckaroo Banzai
parent c3bed5d5c2
commit 27c134f41e

View File

@ -1,5 +1,3 @@
local S = technic.getter
minetest.register_craft({ minetest.register_craft({
output = 'technic:hv_cable 3', output = 'technic:hv_cable 3',
recipe = { recipe = {
@ -11,16 +9,28 @@ minetest.register_craft({
technic.register_cable("HV", 3/16) technic.register_cable("HV", 3/16)
minetest.register_craft({ if minetest.get_modpath("digilines") then
local S = technic.getter
if minetest.get_modpath("digistuff") then
minetest.register_craft({
output = 'technic:hv_digi_cable 1',
type = "shapeless",
recipe = {'digistuff:digimese', 'technic:hv_cable'}
})
else
minetest.register_craft({
output = 'technic:hv_digi_cable 1', output = 'technic:hv_digi_cable 1',
recipe = { recipe = {
{'digilines:wire_std_00000000', 'digilines:wire_std_00000000', 'digilines:wire_std_00000000'}, {'digilines:wire_std_00000000', 'digilines:wire_std_00000000', 'digilines:wire_std_00000000'},
{'digilines:wire_std_00000000', 'technic:hv_cable', 'digilines:wire_std_00000000'}, {'digilines:wire_std_00000000', 'technic:hv_cable', 'digilines:wire_std_00000000'},
{'digilines:wire_std_00000000', 'digilines:wire_std_00000000', 'digilines:wire_std_00000000'}, {'digilines:wire_std_00000000', 'digilines:wire_std_00000000', 'digilines:wire_std_00000000'},
} }
}) })
end
technic.register_cable("HV", 3/16, S("HV Cable (digiline)"), "_digi", { technic.register_cable("HV", 3/16, S("HV Cable (digiline)"), "_digi", {
digiline = { digiline = {
wire = { wire = {
rules = { rules = {
@ -33,4 +43,5 @@ technic.register_cable("HV", 3/16, S("HV Cable (digiline)"), "_digi", {
} }
} }
} }
}) })
end