Add mod check for strut register

This commit is contained in:
GreenXenith 2018-11-26 12:23:58 -08:00 committed by Nathanaël Courant
parent 3cafe7553a
commit f5bf0d98b1

@ -193,7 +193,6 @@ end
minetest.register_node(":technic:insulator_clip", iclip_def) minetest.register_node(":technic:insulator_clip", iclip_def)
minetest.register_node(":technic:insulator_clip_fencepost", iclipfence_def) minetest.register_node(":technic:insulator_clip_fencepost", iclipfence_def)
minetest.register_node(":technic:steel_strut_with_insulator_clip", sclip_def)
minetest.register_craft({ minetest.register_craft({
output = "technic:insulator_clip", output = "technic:insulator_clip",
@ -215,33 +214,35 @@ minetest.register_craft({
local steelmod = minetest.get_modpath("steel") local steelmod = minetest.get_modpath("steel")
if steelmod then if streetsmod or steelmod then
minetest.register_craft({ minetest.register_node(":technic:steel_strut_with_insulator_clip", sclip_def)
output = "technic:steel_strut_with_insulator_clip",
recipe = {
{"technic:insulator_clip_fencepost"},
{"steel:strut_mount"}
}
})
minetest.register_craft({ if steelmod then
output = "technic:steel_strut_with_insulator_clip", minetest.register_craft({
recipe = { output = "technic:steel_strut_with_insulator_clip",
{"technic:insulator_clip_fencepost", "" }, recipe = {
{"steel:strut", "default:steel_ingot" }, {"technic:insulator_clip_fencepost"},
} {"steel:strut_mount"}
}) }
})
end minetest.register_craft({
output = "technic:steel_strut_with_insulator_clip",
recipe = {
{"technic:insulator_clip_fencepost", "" },
{"steel:strut", "default:steel_ingot" },
}
})
if streetsmod then elseif streetsmod then
minetest.register_craft({ minetest.register_craft({
output = "technic:steel_strut_with_insulator_clip", output = "technic:steel_strut_with_insulator_clip",
recipe = { recipe = {
{"technic:insulator_clip_fencepost", "" }, {"technic:insulator_clip_fencepost", "" },
{"streets:steel_support", "default:steel_ingot" }, {"streets:steel_support", "default:steel_ingot" },
} }
}) })
end
end end
if minetest.get_modpath("unifieddyes") then if minetest.get_modpath("unifieddyes") then