diff options
-rw-r--r-- | crafts.lua | 9 | ||||
-rw-r--r-- | depends.txt | 1 | ||||
-rw-r--r-- | init.lua | 8 | ||||
-rw-r--r-- | node_defs.lua | 9 |
4 files changed, 7 insertions, 20 deletions
@@ -1,11 +1,4 @@ --- Boilerplate to support localized strings if intllib mod is installed. -local S -if (minetest.get_modpath("intllib")) then - dofile(minetest.get_modpath("intllib").."/intllib.lua") - S = intllib.Getter(minetest.get_current_modname()) -else - S = function ( s ) return s end -end +local S = moretrees.intllib for i in ipairs(moretrees.treelist) do local treename = moretrees.treelist[i][1] diff --git a/depends.txt b/depends.txt index cacd7e6..1cd5974 100644 --- a/depends.txt +++ b/depends.txt @@ -1,4 +1,5 @@ default plants_lib moreblocks? +intllib? @@ -45,12 +45,12 @@ end -- Boilerplate to support localized strings if intllib mod is installed. local S -if (minetest.get_modpath("intllib")) then - dofile(minetest.get_modpath("intllib").."/intllib.lua") - S = intllib.Getter(minetest.get_current_modname()) +if minetest.get_modpath("intllib") then + S = intllib.Getter() else - S = function ( s ) return s end + S = function(s) return s end end +moretrees.intllib = S -- infinite stacks checking diff --git a/node_defs.lua b/node_defs.lua index d8bf7e9..c5ad566 100644 --- a/node_defs.lua +++ b/node_defs.lua @@ -1,11 +1,4 @@ --- Boilerplate to support localized strings if intllib mod is installed. -local S -if (minetest.get_modpath("intllib")) then - dofile(minetest.get_modpath("intllib").."/intllib.lua") - S = intllib.Getter(minetest.get_current_modname()) -else - S = function ( s ) return s end -end +local S = moretrees.intllib moretrees.avoidnodes = {} |