nalc/nalc_carts/init.lua

43 lines
1.2 KiB
Lua

-- Rail
minetest.clear_craft( {output = "default:rail" })
-- Rail Copper
if minetest.get_modpath("moreores") then
minetest.clear_craft({ output = "moreores:copper_rail" })
else
minetest.clear_craft({ output = "carts:copperrail" })
end
minetest.register_craft(
{
output = "carts:copperrail 16",
recipe = {
{"default:copper_ingot", "default:stick", "default:copper_ingot"},
{"default:copper_ingot", "default:stick", "default:copper_ingot"},
{"default:copper_ingot", "default:stick", "default:copper_ingot"},
}
})
-- Rail Power
minetest.clear_craft({ output = "carts:powerrail" })
minetest.register_craft({
type = "shapeless",
output = "carts:powerrail",
recipe = {"group:rail", "default:mese_crystal_fragment"},
})
-- Rail Brake
minetest.clear_craft({ output = "carts:brakerail" })
minetest.register_craft({
type = "shapeless",
output = "carts:brakerail",
recipe = {"group:rail", "default:coal_lump"},
})
-- Aliases
minetest.register_alias("carts:rail_copper", "carts:copperrail")
minetest.register_alias("carts:rail_brake", "carts:brakerail")
minetest.register_alias("carts:rail_power", "carts:powerrail")
minetest.log("action", "[nalc_carts] loaded.")