mirror of
https://github.com/luanti-org/luanti.git
synced 2025-07-27 17:28:41 +00:00
Translate builtin (#10693)
This PR is the second attempt to translate builtin. Server-sent translation files can be added to `builtin/locale/`, whereas client-side translations depend on gettext.
This commit is contained in:
parent
ac8ac19169
commit
cafad6ac03
12 changed files with 623 additions and 334 deletions
|
@ -1,5 +1,7 @@
|
|||
-- Minetest: builtin/misc_register.lua
|
||||
|
||||
local S = core.get_translator("__builtin")
|
||||
|
||||
--
|
||||
-- Make raw registration functions inaccessible to anyone except this file
|
||||
--
|
||||
|
@ -326,7 +328,7 @@ end
|
|||
|
||||
core.register_item(":unknown", {
|
||||
type = "none",
|
||||
description = "Unknown Item",
|
||||
description = S("Unknown Item"),
|
||||
inventory_image = "unknown_item.png",
|
||||
on_place = core.item_place,
|
||||
on_secondary_use = core.item_secondary_use,
|
||||
|
@ -336,7 +338,7 @@ core.register_item(":unknown", {
|
|||
})
|
||||
|
||||
core.register_node(":air", {
|
||||
description = "Air",
|
||||
description = S("Air"),
|
||||
inventory_image = "air.png",
|
||||
wield_image = "air.png",
|
||||
drawtype = "airlike",
|
||||
|
@ -353,7 +355,7 @@ core.register_node(":air", {
|
|||
})
|
||||
|
||||
core.register_node(":ignore", {
|
||||
description = "Ignore",
|
||||
description = S("Ignore"),
|
||||
inventory_image = "ignore.png",
|
||||
wield_image = "ignore.png",
|
||||
drawtype = "airlike",
|
||||
|
@ -370,7 +372,7 @@ core.register_node(":ignore", {
|
|||
core.chat_send_player(
|
||||
placer:get_player_name(),
|
||||
core.colorize("#FF0000",
|
||||
"You can't place 'ignore' nodes!"))
|
||||
S("You can't place 'ignore' nodes!")))
|
||||
return ""
|
||||
end,
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue