Add more translator comments
This commit is contained in:
parent
36ee708575
commit
9949464e1c
@ -1033,14 +1033,17 @@ function achievements.get_formspec(name)
|
|||||||
if achievement_times then
|
if achievement_times then
|
||||||
if achievement_times == -1 then
|
if achievement_times == -1 then
|
||||||
gotten = true
|
gotten = true
|
||||||
|
--~ gotten achievement
|
||||||
progress = minetest.colorize(COLOR_GOTTEN, S("Gotten"))
|
progress = minetest.colorize(COLOR_GOTTEN, S("Gotten"))
|
||||||
title = minetest.colorize(COLOR_GOTTEN, title)
|
title = minetest.colorize(COLOR_GOTTEN, title)
|
||||||
description = minetest.colorize(COLOR_GOTTEN, description)
|
description = minetest.colorize(COLOR_GOTTEN, description)
|
||||||
else
|
else
|
||||||
local part, total = get_progress(player, aname, def, states)
|
local part, total = get_progress(player, aname, def, states)
|
||||||
|
--~ Achievement progress counter. @1 = number of tasks to complete to get an achievement, @2 = total number of tasks in that achievement
|
||||||
progress = S("@1/@2", part, total)
|
progress = S("@1/@2", part, total)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
|
--~ missing achievement
|
||||||
progress = S("Missing")
|
progress = S("Missing")
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -1051,7 +1054,9 @@ function achievements.get_formspec(name)
|
|||||||
if def.subconditions then
|
if def.subconditions then
|
||||||
local progress_subconds = get_completed_subconditions(player, aname)
|
local progress_subconds = get_completed_subconditions(player, aname)
|
||||||
if #progress_subconds > 0 then
|
if #progress_subconds > 0 then
|
||||||
|
--~ List separator. Used for the list of completed achievement subconditions
|
||||||
local progress_subconds_str = table.concat(progress_subconds, S(", "))
|
local progress_subconds_str = table.concat(progress_subconds, S(", "))
|
||||||
|
--~ Shows the progress of an achievement with subconditions. @1 is a list of all such completed subconditions
|
||||||
description = description .. "\n\n" .. S("Completed: @1", progress_subconds_str)
|
description = description .. "\n\n" .. S("Completed: @1", progress_subconds_str)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -1130,6 +1135,7 @@ function achievements.get_formspec(name)
|
|||||||
|
|
||||||
-- Achievement progress summary
|
-- Achievement progress summary
|
||||||
local progress_total =
|
local progress_total =
|
||||||
|
--~ @1, @2 and @3 are numbers that count achievements
|
||||||
S("@1 of @2 achievements gotten, @3 in progress",
|
S("@1 of @2 achievements gotten, @3 in progress",
|
||||||
amt_gotten,
|
amt_gotten,
|
||||||
#achievements.registered_achievements_list,
|
#achievements.registered_achievements_list,
|
||||||
@ -1227,6 +1233,7 @@ minetest.register_on_player_receive_fields(receive_fields)
|
|||||||
-- Chat command to manipulate and review player achievements
|
-- Chat command to manipulate and review player achievements
|
||||||
minetest.register_chatcommand("achievement", {
|
minetest.register_chatcommand("achievement", {
|
||||||
privs = {server=true},
|
privs = {server=true},
|
||||||
|
--~ chat command syntax for /achievement. You can translate the parts between “<” and “>”, but the rest MUST be left intact
|
||||||
params = S("(list [<player>]) | ((give | remove) <player> (<achievement> | all))"),
|
params = S("(list [<player>]) | ((give | remove) <player> (<achievement> | all))"),
|
||||||
description = S("List, give or remove achievements of player"),
|
description = S("List, give or remove achievements of player"),
|
||||||
func = function(name, param)
|
func = function(name, param)
|
||||||
@ -1243,8 +1250,10 @@ minetest.register_chatcommand("achievement", {
|
|||||||
if ach.difficulty then
|
if ach.difficulty then
|
||||||
difficulty = loc.num(ach.difficulty)
|
difficulty = loc.num(ach.difficulty)
|
||||||
else
|
else
|
||||||
|
--~ Shown when the achievement difficulty has not been set
|
||||||
difficulty = S("unset")
|
difficulty = S("unset")
|
||||||
end
|
end
|
||||||
|
--~ List entry. @1 = technical achievement name, @2 = achievement name, @3 = achievement difficulty rating
|
||||||
local str = BULLET_PRE .. S("@1: @2 (@3)", aname, ach.title, difficulty)
|
local str = BULLET_PRE .. S("@1: @2 (@3)", aname, ach.title, difficulty)
|
||||||
table.insert(strs, str)
|
table.insert(strs, str)
|
||||||
end
|
end
|
||||||
@ -1268,11 +1277,13 @@ minetest.register_chatcommand("achievement", {
|
|||||||
for _, aname in ipairs(achievements.registered_achievements_list) do
|
for _, aname in ipairs(achievements.registered_achievements_list) do
|
||||||
local status = achievements.get_completion_status(player, aname)
|
local status = achievements.get_completion_status(player, aname)
|
||||||
if status == achievements.ACHIEVEMENT_GOTTEN then
|
if status == achievements.ACHIEVEMENT_GOTTEN then
|
||||||
|
--~ @1 = achievement name
|
||||||
local str = BULLET_PRE .. S("@1: Gotten", aname)
|
local str = BULLET_PRE .. S("@1: Gotten", aname)
|
||||||
table.insert(strs, str)
|
table.insert(strs, str)
|
||||||
elseif status == achievements.ACHIEVEMENT_IN_PROGRESS then
|
elseif status == achievements.ACHIEVEMENT_IN_PROGRESS then
|
||||||
local ach = achievements.registered_achievements[aname]
|
local ach = achievements.registered_achievements[aname]
|
||||||
local part, total = get_progress(player, aname, ach, get_achievement_states(player))
|
local part, total = get_progress(player, aname, ach, get_achievement_states(player))
|
||||||
|
--~ @1 = achievement name, @2 and @3 are numbers for a progress counter
|
||||||
local str = BULLET_PRE .. S("@1: In progress (@2/@3)", aname, part, total)
|
local str = BULLET_PRE .. S("@1: In progress (@2/@3)", aname, part, total)
|
||||||
table.insert(strs, str)
|
table.insert(strs, str)
|
||||||
end
|
end
|
||||||
@ -1281,6 +1292,7 @@ minetest.register_chatcommand("achievement", {
|
|||||||
if output == "" then
|
if output == "" then
|
||||||
output = S("No achievements.")
|
output = S("No achievements.")
|
||||||
else
|
else
|
||||||
|
--~ @1 = player name
|
||||||
output = S("Achievements of @1:", playername).."\n"..output
|
output = S("Achievements of @1:", playername).."\n"..output
|
||||||
end
|
end
|
||||||
return true, output
|
return true, output
|
||||||
|
@ -219,11 +219,13 @@ function armor.get_formspec(name)
|
|||||||
form = form .. "image[5,1.75;1,1;rp_armor_icon_protection.png]"
|
form = form .. "image[5,1.75;1,1;rp_armor_icon_protection.png]"
|
||||||
form = form .. "tooltip[5,1.75;1,1;"..FS("Protection").."]"
|
form = form .. "tooltip[5,1.75;1,1;"..FS("Protection").."]"
|
||||||
form = form .. "style_type[label;font_size=*2]"
|
form = form .. "style_type[label;font_size=*2]"
|
||||||
|
--~ armor protection percentage, shown in armor page
|
||||||
form = form .. "label[6.1,2.25;"..S("@1%", armor_full).."]"
|
form = form .. "label[6.1,2.25;"..S("@1%", armor_full).."]"
|
||||||
if armor_bonus ~= 0 then
|
if armor_bonus ~= 0 then
|
||||||
form = form .. "style_type[label;font_size=]"
|
form = form .. "style_type[label;font_size=]"
|
||||||
form = form .. "image[2.45,4.05;0.5,0.5;rp_armor_icon_bonus.png]"
|
form = form .. "image[2.45,4.05;0.5,0.5;rp_armor_icon_bonus.png]"
|
||||||
form = form .. "tooltip[2.45,4.05;0.5,0.5;"..FS("Protection bonus for full set").."]"
|
form = form .. "tooltip[2.45,4.05;0.5,0.5;"..FS("Protection bonus for full set").."]"
|
||||||
|
--~ protection bonus for wearing full set, shown in armor page
|
||||||
form = form .. "label[3,4.3;"..S("+@1%", armor_bonus).."]"
|
form = form .. "label[3,4.3;"..S("+@1%", armor_bonus).."]"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -119,6 +119,7 @@ book.register_book_node(
|
|||||||
|
|
||||||
local set_meta_description = function(meta, title)
|
local set_meta_description = function(meta, title)
|
||||||
if title ~= "" then
|
if title ~= "" then
|
||||||
|
--~ @1 = book title
|
||||||
meta:set_string("description", S("Book: “@1”", minetest.colorize("#ffff00", title))) -- Set the item description
|
meta:set_string("description", S("Book: “@1”", minetest.colorize("#ffff00", title))) -- Set the item description
|
||||||
else
|
else
|
||||||
meta:set_string("description", "")
|
meta:set_string("description", "")
|
||||||
|
@ -48,6 +48,7 @@ local function get_bookshelf_formspec(pos)
|
|||||||
for i=1,8 do
|
for i=1,8 do
|
||||||
if inv:get_stack("main", i):get_name() == "rp_default:book" then
|
if inv:get_stack("main", i):get_name() == "rp_default:book" then
|
||||||
local xoff = (i-1) * 1.25
|
local xoff = (i-1) * 1.25
|
||||||
|
--~ Button tooltip in bookshelf to read a book
|
||||||
form = form .. rp_formspec.image_button(xstart+xoff, ystart + 1.15, 1, 1, "open_"..i, "ui_icon_view.png", S("Read book"))
|
form = form .. rp_formspec.image_button(xstart+xoff, ystart + 1.15, 1, 1, "open_"..i, "ui_icon_view.png", S("Read book"))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -172,6 +173,7 @@ minetest.register_on_player_receive_fields(
|
|||||||
local form = rp_formspec.get_page("rp_book:book_page")
|
local form = rp_formspec.get_page("rp_book:book_page")
|
||||||
form = form .. rp_book.make_read_book_page_formspec(title, text)
|
form = form .. rp_book.make_read_book_page_formspec(title, text)
|
||||||
|
|
||||||
|
--~ Button to return from book reading screen (bookshelf)
|
||||||
form = form .. rp_formspec.button(3.5, 9, 3, 1, "return", S("Return"))
|
form = form .. rp_formspec.button(3.5, 9, 3, 1, "return", S("Return"))
|
||||||
minetest.sound_play({name="rp_book_open_book", gain=0.5}, {pos=player:get_pos(), max_hear_distance=16}, true)
|
minetest.sound_play({name="rp_book_open_book", gain=0.5}, {pos=player:get_pos(), max_hear_distance=16}, true)
|
||||||
minetest.show_formspec(pname, "rp_default:read_book_in_bookshelf", form)
|
minetest.show_formspec(pname, "rp_default:read_book_in_bookshelf", form)
|
||||||
|
@ -4,6 +4,7 @@ local mod_death_messages = minetest.get_modpath("rp_death_messages") ~= nil
|
|||||||
|
|
||||||
minetest.register_chatcommand("hp", {
|
minetest.register_chatcommand("hp", {
|
||||||
privs = {server=true},
|
privs = {server=true},
|
||||||
|
--~ command syntax for /hp command. Translate the words, but the symbols MUST be left intact
|
||||||
params = S("[<player>] <value>"),
|
params = S("[<player>] <value>"),
|
||||||
description = S("Set health points of player or yourself"),
|
description = S("Set health points of player or yourself"),
|
||||||
func = function(name, param)
|
func = function(name, param)
|
||||||
|
@ -653,6 +653,7 @@ end
|
|||||||
minetest.register_chatcommand("hunger", {
|
minetest.register_chatcommand("hunger", {
|
||||||
description = S("Set hunger level of player or yourself"),
|
description = S("Set hunger level of player or yourself"),
|
||||||
privs = { server = true },
|
privs = { server = true },
|
||||||
|
--~ Syntax for /hunger command. You may translate the words, but the symbols MUST be left intact.
|
||||||
params = S("[<player>] <hunger>"),
|
params = S("[<player>] <hunger>"),
|
||||||
func = function(playername, param)
|
func = function(playername, param)
|
||||||
-- Set hunger of specified target player
|
-- Set hunger of specified target player
|
||||||
|
@ -123,7 +123,7 @@ function jewels.register_jewel(toolname, new_toolname, def)
|
|||||||
if not desc then
|
if not desc then
|
||||||
desc = new_toolname
|
desc = new_toolname
|
||||||
else
|
else
|
||||||
-- Fallback description
|
--~ Fallback description for jeweled tools that don’t provide their own description. @1 = name of original tool that has been jeweled
|
||||||
desc = S("@1 (jeweled)", desc)
|
desc = S("@1 (jeweled)", desc)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -192,6 +192,7 @@ end
|
|||||||
local amendments = {
|
local amendments = {
|
||||||
{ "range", NS("Range bonus: @1") },
|
{ "range", NS("Range bonus: @1") },
|
||||||
{ "maxdrop", NS("Drop level bonus: @1") },
|
{ "maxdrop", NS("Drop level bonus: @1") },
|
||||||
|
--~ dig time bonus for jeweled tools. “s” stands for “seconds”
|
||||||
{ "digspeed", NS("Dig time bonus: @1 s") },
|
{ "digspeed", NS("Dig time bonus: @1 s") },
|
||||||
{ "uses", NS("Durability bonus: @1") },
|
{ "uses", NS("Durability bonus: @1") },
|
||||||
{ "maxlevel", NS("Dig level bonus: @1") },
|
{ "maxlevel", NS("Dig level bonus: @1") },
|
||||||
|
@ -117,6 +117,7 @@ local change_bucket_level = function(pos, node, level_change)
|
|||||||
elseif old_paint_level == 0 and paint_level > 0 then
|
elseif old_paint_level == 0 and paint_level > 0 then
|
||||||
local meta = minetest.get_meta(pos)
|
local meta = minetest.get_meta(pos)
|
||||||
local color = bit.rshift(node.param2, 2)
|
local color = bit.rshift(node.param2, 2)
|
||||||
|
--~ @1 = color name of color contained in paint bucket
|
||||||
meta:set_string("infotext", S("Paint Bucket (@1)", COLOR_NAMES[color+1]))
|
meta:set_string("infotext", S("Paint Bucket (@1)", COLOR_NAMES[color+1]))
|
||||||
end
|
end
|
||||||
-- Return actual level change
|
-- Return actual level change
|
||||||
|
Loading…
x
Reference in New Issue
Block a user