zh_TW Translations (#76)

This commit is contained in:
Emo"jigit 2022-08-13 21:03:12 +08:00 committed by GitHub
parent f03cd02854
commit d35f7f12c4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 53 additions and 9 deletions

View File

@ -1,5 +1,5 @@
digilines = {} digilines = {}
digilines.S = minetest.get_translator("digilines")
-- Backwards compatibility code. -- Backwards compatibility code.
-- We define a proxy table whose methods can be called with the -- We define a proxy table whose methods can be called with the

View File

@ -1,3 +1,5 @@
local S = digilines.S
local pipeworks_enabled = minetest.get_modpath("pipeworks") ~= nil local pipeworks_enabled = minetest.get_modpath("pipeworks") ~= nil
-- Sends a message onto the Digilines network. -- Sends a message onto the Digilines network.
@ -146,7 +148,7 @@ end
minetest.register_alias("digilines_inventory:chest", "digilines:chest") minetest.register_alias("digilines_inventory:chest", "digilines:chest")
minetest.register_node("digilines:chest", { minetest.register_node("digilines:chest", {
description = "Digiline Chest", description = S("Digiline Chest"),
tiles = { tiles = {
"default_chest_top.png"..tubeconn, "default_chest_top.png"..tubeconn,
"default_chest_top.png"..tubeconn, "default_chest_top.png"..tubeconn,
@ -161,14 +163,14 @@ minetest.register_node("digilines:chest", {
sounds = default.node_sound_wood_defaults(), sounds = default.node_sound_wood_defaults(),
on_construct = function(pos) on_construct = function(pos)
local meta = minetest.get_meta(pos) local meta = minetest.get_meta(pos)
meta:set_string("infotext", "Digiline Chest") meta:set_string("infotext", S("Digiline Chest"))
meta:set_string("formspec", "size[8,10]".. meta:set_string("formspec", "size[8,10]"..
((default and default.gui_bg) or "").. ((default and default.gui_bg) or "")..
((default and default.gui_bg_img) or "").. ((default and default.gui_bg_img) or "")..
((default and default.gui_slots) or "").. ((default and default.gui_slots) or "")..
"label[0,0;Digiline Chest]".. "label[0,0;" .. S("Digiline Chest") .. "]" ..
"list[current_name;main;0,1;8,4;]".. "list[current_name;main;0,1;8,4;]"..
"field[2,5.5;5,1;channel;Channel;${channel}]".. "field[2,5.5;5,1;channel;" .. S("Channel") .. ";${channel}]"..
((default and default.get_hotbar_bg) and default.get_hotbar_bg(0,6) or "").. ((default and default.get_hotbar_bg) and default.get_hotbar_bg(0,6) or "")..
"list[current_player;main;0,6;8,4;]".. "list[current_player;main;0,6;8,4;]"..
"listring[]") "listring[]")

View File

@ -1,3 +1,5 @@
local S = digilines.S
--* parts are currently not possible because you cannot set the pitch of an entity from lua --* parts are currently not possible because you cannot set the pitch of an entity from lua
-- Font: 04.jp.org -- Font: 04.jp.org
@ -270,7 +272,7 @@ local lcd_box = {
minetest.register_alias("digilines_lcd:lcd", "digilines:lcd") minetest.register_alias("digilines_lcd:lcd", "digilines:lcd")
minetest.register_node("digilines:lcd", { minetest.register_node("digilines:lcd", {
drawtype = "nodebox", drawtype = "nodebox",
description = "Digiline LCD", description = S("Digiline LCD"),
inventory_image = "lcd_lcd.png", inventory_image = "lcd_lcd.png",
wield_image = "lcd_lcd.png", wield_image = "lcd_lcd.png",
tiles = {"lcd_anyside.png"}, tiles = {"lcd_anyside.png"},

View File

@ -1,3 +1,5 @@
local S = digilines.S
local GET_COMMAND = "GET" local GET_COMMAND = "GET"
local lsensor_nodebox = local lsensor_nodebox =
@ -31,7 +33,7 @@ end
minetest.register_alias("digilines_lightsensor:lightsensor", "digilines:lightsensor") minetest.register_alias("digilines_lightsensor:lightsensor", "digilines:lightsensor")
minetest.register_node("digilines:lightsensor", { minetest.register_node("digilines:lightsensor", {
description = "Digiline Lightsensor", description = S("Digiline Lightsensor"),
drawtype = "nodebox", drawtype = "nodebox",
tiles = {"digilines_lightsensor.png"}, tiles = {"digilines_lightsensor.png"},

17
locale/digilines.zh_TW.tr Normal file
View File

@ -0,0 +1,17 @@
# textdomain: digilines
### inventory.lua ###
Digiline Chest=訊纜儲物箱
Channel=頻道
### lcd.lua ###
Digiline LCD=訊纜 LCD
### lightsensor.lua ###
Digiline Lightsensor=訊纜光感應器
### rtc.lua ###
Digiline Real Time Clock (RTC)=訊纜實時時鐘
### wire_std.lua ###
Digiline=訊纜

17
locale/template.txt Normal file
View File

@ -0,0 +1,17 @@
# textdomain: digilines
### inventory.lua ###
Digiline Chest=
Channel=
### lcd.lua ###
Digiline LCD=
### lightsensor.lua ###
Digiline Lightsensor=
### rtc.lua ###
Digiline Real Time Clock (RTC)=
### wire_std.lua ###
Digiline=

View File

@ -1,3 +1,5 @@
local S = digilines.S
local GET_COMMAND = "GET" local GET_COMMAND = "GET"
local rtc_nodebox = local rtc_nodebox =
@ -26,7 +28,7 @@ end
minetest.register_alias("digilines_rtc:rtc", "digilines:rtc") minetest.register_alias("digilines_rtc:rtc", "digilines:rtc")
minetest.register_node("digilines:rtc", { minetest.register_node("digilines:rtc", {
description = "Digiline Real Time Clock (RTC)", description = S("Digiline Real Time Clock (RTC)"),
drawtype = "nodebox", drawtype = "nodebox",
tiles = {"digilines_rtc.png"}, tiles = {"digilines_rtc.png"},

View File

@ -1,3 +1,5 @@
local S = digilines.S
-- naming scheme: wire:(xp)(zp)(xm)(zm)_on/off -- naming scheme: wire:(xp)(zp)(xm)(zm)_on/off
-- The conditions in brackets define whether there is a digiline at that place or not -- The conditions in brackets define whether there is a digiline at that place or not
-- 1 = there is one; 0 = there is none -- 1 = there is one; 0 = there is none
@ -36,7 +38,7 @@ for zmy=0, 1 do
if nodeid == "00000000" then if nodeid == "00000000" then
groups = {dig_immediate = 3} groups = {dig_immediate = 3}
wiredesc = "Digiline" wiredesc = S("Digiline")
else else
groups = {dig_immediate = 3, not_in_creative_inventory = 1} groups = {dig_immediate = 3, not_in_creative_inventory = 1}
end end