summaryrefslogtreecommitdiff
path: root/init.lua
diff options
context:
space:
mode:
authorWuzzy <almikes@aol.com>2016-10-13 06:16:03 +0200
committerWuzzy <almikes@aol.com>2016-10-13 06:16:03 +0200
commit304d13ac6d19ff3224479b633159b0af78ad9667 (patch)
treecd8c931d6d77d97c92142a5ac7163ff2c0c55cc1 /init.lua
parent132a01cd0f8a360d8aa3df3c7b87125657abe503 (diff)
Make missing category pages more onsistent
Diffstat (limited to 'init.lua')
-rw-r--r--init.lua8
1 files changed, 5 insertions, 3 deletions
diff --git a/init.lua b/init.lua
index f552062..c58d2c2 100644
--- a/init.lua
+++ b/init.lua
@@ -635,8 +635,9 @@ end
function doc.formspec_category(id, playername)
local formstring
if id == nil then
- formstring = "label[0,0.5;"..F("You haven't chosen a category yet. Please choose one in the category list first.").."]"
- formstring = formstring .. "button[0,1.5;3,1;doc_button_goto_main;"..F("Go to category list").."]"
+ formstring = "label[0,0;"..F("Help > (No Category)") .. "]"
+ formstring = formstring .. "label[0,0.5;"..F("You haven't chosen a category yet. Please choose one in the category list first.").."]"
+ formstring = formstring .. "button[0,1;3,1;doc_button_goto_main;"..F("Go to category list").."]"
else
formstring = "label[0,0;"..minetest.formspec_escape(string.format(S("Help > %s"), doc.data.categories[id].def.name)).."]"
local total = doc.get_entry_count(id)
@@ -689,7 +690,8 @@ end
function doc.formspec_entry(category_id, entry_id)
local formstring
if category_id == nil then
- formstring = "label[0,0;"..F("You haven't chosen a category yet. Please choose one in the category list first.").."]"
+ formstring = "label[0,0;"..F("Help > (No Category)") .. "]"
+ formstring = formstring .. "label[0,0.5;"..F("You haven't chosen a category yet. Please choose one in the category list first.").."]"
formstring = formstring .. "button[0,1;3,1;doc_button_goto_main;"..F("Go to category list").."]"
elseif entry_id == nil then
formstring = "label[0,0;"..minetest.formspec_escape(string.format(S("Help > %s > (No Entry)"), doc.data.categories[category_id].def.name)) .. "]"