diff options
author | Wuzzy <almikes@aol.com> | 2016-07-24 17:45:25 +0200 |
---|---|---|
committer | Wuzzy <almikes@aol.com> | 2016-07-24 17:45:25 +0200 |
commit | 35b5c9acdd0f80972e3f5e297a00d651cedb93e7 (patch) | |
tree | 891c5bba006a063344845bdbb0c15e5b35a7bb3c /init.lua | |
parent | 122245edce64ff88307a27ae43101274bc945e75 (diff) |
Add support to add texts from external source
Diffstat (limited to 'init.lua')
-rw-r--r-- | init.lua | 16 |
1 files changed, 14 insertions, 2 deletions
@@ -411,12 +411,24 @@ doc.new_category("craftitems", { end }) - - +doc.sub.minetest_game = {} +doc.sub.minetest_game.help = {} +doc.sub.minetest_game.help.longdesc = {} +doc.sub.minetest_game.help.usagehelp = {} +-- Gather help texts +function doc.sub.minetest_game.add_helptexts(longdesc, usagehelp) + for k,v in pairs(longdesc) do + doc.sub.minetest_game.help.longdesc[k] = v + end + for k,v in pairs(usagehelp) do + doc.sub.minetest_game.help.usagehelp[k] = v + end +end dofile(minetest.get_modpath("doc_minetest_game") .. "/helptexts.lua") local function gather_descs() + local help = doc.sub.minetest_game.help doc.new_entry("nodes", "air", { name = "Air", data = { |