From fc71cfe1fced0313d03afd8c520a3258941e5016 Mon Sep 17 00:00:00 2001 From: "A. Demant" Date: Tue, 18 Dec 2018 19:08:54 +0100 Subject: [PATCH] add several integrations --- ethereal.lua | 6 ++++++ init.lua | 13 +++++++++++++ mod.conf | 3 +-- moretrees.lua | 4 ++++ woodsoil.lua | 6 ++++++ 5 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 ethereal.lua create mode 100644 init.lua create mode 100644 moretrees.lua create mode 100644 woodsoil.lua diff --git a/ethereal.lua b/ethereal.lua new file mode 100644 index 0000000..60f4e2f --- /dev/null +++ b/ethereal.lua @@ -0,0 +1,6 @@ +if minetest.get_modpath("ethereal") ~= nil then + farming.add_soil("ethereal:jungle_dirt") + farming.add_soil("ethereal:gray_dirt") + farming.add_soil("ethereal:cold_dirt") + farming.add_soil("ethereal:bamboo_dirt") +end diff --git a/init.lua b/init.lua new file mode 100644 index 0000000..b6a3aa4 --- /dev/null +++ b/init.lua @@ -0,0 +1,13 @@ +minetest.log("action", "[MOD]"..minetest.get_current_modname().." -- start loading from "..minetest.get_modpath(minetest.get_current_modname())) + +if minetest.get_modpath("moretrees") ~= nil then + dofile(minetest.get_modpath("farming_integrate") .. "/moretrees.lua") +end +if minetest.get_modpath("woodsoil") ~= nil then + dofile(minetest.get_modpath("farming_integrate") .. "/woodsoil.lua") +end +if minetest.get_modpath("ethereal") ~= nil then + dofile(minetest.get_modpath("farming_integrate") .. "/ethereal.lua") +end + +minetest.log("action", "[MOD]"..minetest.get_current_modname().." -- loaded ") diff --git a/mod.conf b/mod.conf index c73d598..9eecdd7 100644 --- a/mod.conf +++ b/mod.conf @@ -2,7 +2,6 @@ name = farming_integrate title = Farming Integrate author = ademant description = Integrate items from other mods into farming without creating circular dependencies -optional_depends = intllib -optional_depends = farming,ethereal,moretrees +optional_depends = farming,ethereal,moretrees,woodsoil license = MIT version = 1.0.0 diff --git a/moretrees.lua b/moretrees.lua new file mode 100644 index 0000000..0d4d0e0 --- /dev/null +++ b/moretrees.lua @@ -0,0 +1,4 @@ +if minetest.get_modpath("moretrees") ~= nil then + + +end diff --git a/woodsoil.lua b/woodsoil.lua new file mode 100644 index 0000000..31fc0a9 --- /dev/null +++ b/woodsoil.lua @@ -0,0 +1,6 @@ +if minetest.get_modpath("woodsoil") ~= nil then + farming.add_soil("woodsoils:dirt_with_leaves_1") + farming.add_soil("woodsoils:dirt_with_leaves_2") + farming.add_soil("woodsoils:grass_with_leaves_1") + farming.add_soil("woodsoils:grass_with_leaves_2") +end