From c2a5465855beebd4be241c8fc9a37c926c6dbc3c Mon Sep 17 00:00:00 2001 From: Jordan Irwin Date: Sat, 12 Aug 2017 11:42:53 -0700 Subject: [PATCH] [jukebox] Update to Git commit 9f31f08 & patch 5cbba7f: Commit: https://github.com/minetest-mods/jukebox/tree/9f31f08 Patch: https://github.com/AntumMT/mod-jukebox/tree/5cbba7f --- README.md | 5 ++- mods/furniture/jukebox/depends.txt | 2 +- mods/furniture/jukebox/init.lua | 9 ++++- mods/furniture/jukebox/intllib.lua | 45 ++++++++++++++++++++++ mods/furniture/jukebox/locale/be.po | 29 ++++++++++++++ mods/furniture/jukebox/locale/cs.po | 28 ++++++++++++++ mods/furniture/jukebox/locale/fr.po | 28 ++++++++++++++ mods/furniture/jukebox/locale/it.po | 28 ++++++++++++++ mods/furniture/jukebox/locale/ja.po | 29 ++++++++++++++ mods/furniture/jukebox/locale/ms.po | 29 ++++++++++++++ mods/furniture/jukebox/locale/nl.po | 28 ++++++++++++++ mods/furniture/jukebox/locale/template.pot | 26 +++++++++++++ mods/furniture/jukebox/locale/tr.po | 28 ++++++++++++++ mods/furniture/jukebox/locale/zh_Hans.po | 29 ++++++++++++++ 14 files changed, 338 insertions(+), 5 deletions(-) create mode 100644 mods/furniture/jukebox/intllib.lua create mode 100644 mods/furniture/jukebox/locale/be.po create mode 100644 mods/furniture/jukebox/locale/cs.po create mode 100644 mods/furniture/jukebox/locale/fr.po create mode 100644 mods/furniture/jukebox/locale/it.po create mode 100644 mods/furniture/jukebox/locale/ja.po create mode 100644 mods/furniture/jukebox/locale/ms.po create mode 100644 mods/furniture/jukebox/locale/nl.po create mode 100644 mods/furniture/jukebox/locale/template.pot create mode 100644 mods/furniture/jukebox/locale/tr.po create mode 100644 mods/furniture/jukebox/locale/zh_Hans.po diff --git a/README.md b/README.md index ab7cfaa2..9d9c28c1 100644 --- a/README.md +++ b/README.md @@ -42,7 +42,7 @@ The game includes the mods from the default [minetest_game](https://github.com/m * [crops][] ([LGPL / CC BY-SA / CC BY / CC0][lic.crops]) -- version: [2b1bb37 Git][ver.crops] *2017-03-31* ([patched][patch.crops]) * [farming_plus][] ([WTFPL][lic.farming_plus]) -- version: [7e0d976 Git][ver.farming_plus] *2014-07-31* ([patched][patch.farming_plus]) * furniture/ - * [jukebox][] ([WTFPL / CC0][lic.jukebox]) -- version: [e6a507f Git][ver.jukebox] *2016-05-23* ***UPDATE*** + * [jukebox][] ([WTFPL / CC0][lic.jukebox]) -- version: [9f31f08 Git][ver.jukebox] *2017-07-12* ([patched][patch.jukebox]) * [trampoline][] ([GPL][lic.gpl3.0]) -- version: [ab1c289 Git][ver.trampoline] *2017-05-26* * [trash_can][] ([MIT][lic.trash_can]) -- version: [5fd3df7 Git][ver.trash_can] *2016-01-14* ([patched][patch.trash_can]) * [intllib][] ([Unlicense][lic.unlicense]) -- version: [7b818cb Git][ver.intllib] *2017-07-10* @@ -463,7 +463,7 @@ The game includes the mods from the default [minetest_game](https://github.com/m [ver.ilights]: https://github.com/minetest-mods/ilights/tree/fa085fd [ver.intllib]: https://github.com/minetest-mods/intllib/tree/7b818cb [ver.invisibility]: https://github.com/tenplus1/invisibility/tree/bf4156b -[ver.jukebox]: https://github.com/minetest-mods/jukebox/tree/e6a507f +[ver.jukebox]: https://github.com/minetest-mods/jukebox/tree/9f31f08 [ver.lightning]: https://github.com/minetest-mods/lightning/tree/39bd36c [ver.mesecons]: https://github.com/minetest-mods/mesecons/tree/564bdc2 [ver.minetest_game]: https://github.com/minetest/minetest_game/tree/f855bee @@ -553,6 +553,7 @@ The game includes the mods from the default [minetest_game](https://github.com/m [patch.hud]: https://github.com/AntumMT/mod-hud/tree/6846e20 [patch.hudbars]: https://github.com/AntumMT/mod-hudbars/tree/9ca4f6b [patch.invisibility]: https://github.com/AntumMT/mod-invisibility/tree/f045c7c +[patch.jukebox]: https://github.com/AntumMT/mod-jukebox/tree/5cbba7f [patch.mesecons]: https://github.com/AntumMT/mp-mesecons/tree/830823a [patch.minetest_game]: https://github.com/AntumMT/mtgame-minetest/tree/4275126 [patch.mob-engine]: https://github.com/AntumMT/mp-mob-engine/tree/93575e0 diff --git a/mods/furniture/jukebox/depends.txt b/mods/furniture/jukebox/depends.txt index 25f5cd1f..198fe8a6 100644 --- a/mods/furniture/jukebox/depends.txt +++ b/mods/furniture/jukebox/depends.txt @@ -1,2 +1,2 @@ default -craft_guide? \ No newline at end of file +intllib? diff --git a/mods/furniture/jukebox/init.lua b/mods/furniture/jukebox/init.lua index 0a680029..61927235 100644 --- a/mods/furniture/jukebox/init.lua +++ b/mods/furniture/jukebox/init.lua @@ -1,3 +1,7 @@ +-- Load support for intllib. +local MP = minetest.get_modpath(minetest.get_current_modname()) +local S, NS = dofile(MP.."/intllib.lua") + jukebox = {} jukebox.registered_discs = {} @@ -20,7 +24,7 @@ end local handlers = {} minetest.register_node("jukebox:box", { - description = "Jukebox", + description = S("Jukebox"), paramtype2 = "facedir", stack_max = 1, tiles = { @@ -132,7 +136,7 @@ minetest.register_craft({ for i = 1, 9 do local item_name = "jukebox:disc_" .. i - local description = "Music Disc " .. i + local description = S("Music Disc @1", i) local inventory_image = "jukebox_disc_" .. i .. ".png" local music_name = "jukebox_disc_" .. i @@ -151,3 +155,4 @@ minetest.register_craft({ {"", "default:coal_lump", ""} } }) + diff --git a/mods/furniture/jukebox/intllib.lua b/mods/furniture/jukebox/intllib.lua new file mode 100644 index 00000000..6669d720 --- /dev/null +++ b/mods/furniture/jukebox/intllib.lua @@ -0,0 +1,45 @@ + +-- Fallback functions for when `intllib` is not installed. +-- Code released under Unlicense . + +-- Get the latest version of this file at: +-- https://raw.githubusercontent.com/minetest-mods/intllib/master/lib/intllib.lua + +local function format(str, ...) + local args = { ... } + local function repl(escape, open, num, close) + if escape == "" then + local replacement = tostring(args[tonumber(num)]) + if open == "" then + replacement = replacement..close + end + return replacement + else + return "@"..open..num..close + end + end + return (str:gsub("(@?)@(%(?)(%d+)(%)?)", repl)) +end + +local gettext, ngettext +if minetest.get_modpath("intllib") then + if intllib.make_gettext_pair then + -- New method using gettext. + gettext, ngettext = intllib.make_gettext_pair() + else + -- Old method using text files. + gettext = intllib.Getter() + end +end + +-- Fill in missing functions. + +gettext = gettext or function(msgid, ...) + return format(msgid, ...) +end + +ngettext = ngettext or function(msgid, msgid_plural, n, ...) + return format(n==1 and msgid or msgid_plural, ...) +end + +return gettext, ngettext diff --git a/mods/furniture/jukebox/locale/be.po b/mods/furniture/jukebox/locale/be.po new file mode 100644 index 00000000..4e2f29b1 --- /dev/null +++ b/mods/furniture/jukebox/locale/be.po @@ -0,0 +1,29 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-04 22:01+0200\n" +"PO-Revision-Date: 2017-07-07 15:16+0000\n" +"Last-Translator: Viktar Vauchkevich \n" +"Language-Team: Belarusian \n" +"Language: be\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=" +"4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" +"X-Generator: Weblate 2.16-dev\n" + +#: init.lua +msgid "Jukebox" +msgstr "Музычны аўтамат" + +#: init.lua +msgid "Music Disc @1" +msgstr "Музычны дыск @1" diff --git a/mods/furniture/jukebox/locale/cs.po b/mods/furniture/jukebox/locale/cs.po new file mode 100644 index 00000000..5b7c177a --- /dev/null +++ b/mods/furniture/jukebox/locale/cs.po @@ -0,0 +1,28 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-04 22:01+0200\n" +"PO-Revision-Date: 2017-06-21 19:58+0000\n" +"Last-Translator: Jakub Vaněk \n" +"Language-Team: Czech \n" +"Language: cs\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n" +"X-Generator: Weblate 2.15-dev\n" + +#: init.lua +msgid "Jukebox" +msgstr "Jukebox" + +#: init.lua +msgid "Music Disc @1" +msgstr "Hudební disk @1" diff --git a/mods/furniture/jukebox/locale/fr.po b/mods/furniture/jukebox/locale/fr.po new file mode 100644 index 00000000..b70b0b91 --- /dev/null +++ b/mods/furniture/jukebox/locale/fr.po @@ -0,0 +1,28 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-04 22:01+0200\n" +"PO-Revision-Date: 2017-07-12 17:07+0000\n" +"Last-Translator: Roberto Albano De Rosa \n" +"Language-Team: French \n" +"Language: fr\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=n > 1;\n" +"X-Generator: Weblate 2.16-dev\n" + +#: init.lua +msgid "Jukebox" +msgstr "Juke-box" + +#: init.lua +msgid "Music Disc @1" +msgstr "Disque de musique @1" diff --git a/mods/furniture/jukebox/locale/it.po b/mods/furniture/jukebox/locale/it.po new file mode 100644 index 00000000..c707be57 --- /dev/null +++ b/mods/furniture/jukebox/locale/it.po @@ -0,0 +1,28 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-04 22:01+0200\n" +"PO-Revision-Date: 2017-07-12 16:28+0000\n" +"Last-Translator: Roberto Albano De Rosa \n" +"Language-Team: Italian \n" +"Language: it\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" +"X-Generator: Weblate 2.16-dev\n" + +#: init.lua +msgid "Jukebox" +msgstr "Jukebox" + +#: init.lua +msgid "Music Disc @1" +msgstr "Disco musicale @1" diff --git a/mods/furniture/jukebox/locale/ja.po b/mods/furniture/jukebox/locale/ja.po new file mode 100644 index 00000000..15f6d0ae --- /dev/null +++ b/mods/furniture/jukebox/locale/ja.po @@ -0,0 +1,29 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-04 22:01+0200\n" +"PO-Revision-Date: 2017-07-03 03:22+0000\n" +"Last-Translator: Muhammad Nur Hidayat Yasuyoshi " +"\n" +"Language-Team: Japanese \n" +"Language: ja\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=1; plural=0;\n" +"X-Generator: Weblate 2.16-dev\n" + +#: init.lua +msgid "Jukebox" +msgstr "ジュークボックス" + +#: init.lua +msgid "Music Disc @1" +msgstr "音楽ディスク @1" diff --git a/mods/furniture/jukebox/locale/ms.po b/mods/furniture/jukebox/locale/ms.po new file mode 100644 index 00000000..2c13aea9 --- /dev/null +++ b/mods/furniture/jukebox/locale/ms.po @@ -0,0 +1,29 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-04 22:01+0200\n" +"PO-Revision-Date: 2017-06-30 18:45+0000\n" +"Last-Translator: Muhammad Nur Hidayat Yasuyoshi " +"\n" +"Language-Team: Malay \n" +"Language: ms\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=1; plural=0;\n" +"X-Generator: Weblate 2.16-dev\n" + +#: init.lua +msgid "Jukebox" +msgstr "Peti Lagu" + +#: init.lua +msgid "Music Disc @1" +msgstr "Disk Lagu @1" diff --git a/mods/furniture/jukebox/locale/nl.po b/mods/furniture/jukebox/locale/nl.po new file mode 100644 index 00000000..160886b2 --- /dev/null +++ b/mods/furniture/jukebox/locale/nl.po @@ -0,0 +1,28 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-04 22:01+0200\n" +"PO-Revision-Date: 2017-07-06 09:53+0000\n" +"Last-Translator: Oscar \n" +"Language-Team: Dutch \n" +"Language: nl\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" +"X-Generator: Weblate 2.16-dev\n" + +#: init.lua +msgid "Jukebox" +msgstr "Jukebox" + +#: init.lua +msgid "Music Disc @1" +msgstr "Muziek disk @1" diff --git a/mods/furniture/jukebox/locale/template.pot b/mods/furniture/jukebox/locale/template.pot new file mode 100644 index 00000000..bb48c8b7 --- /dev/null +++ b/mods/furniture/jukebox/locale/template.pot @@ -0,0 +1,26 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-04 22:01+0200\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME \n" +"Language-Team: LANGUAGE \n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=CHARSET\n" +"Content-Transfer-Encoding: 8bit\n" + +#: init.lua +msgid "Jukebox" +msgstr "" + +#: init.lua +msgid "Music Disc @1" +msgstr "" diff --git a/mods/furniture/jukebox/locale/tr.po b/mods/furniture/jukebox/locale/tr.po new file mode 100644 index 00000000..a226ca7d --- /dev/null +++ b/mods/furniture/jukebox/locale/tr.po @@ -0,0 +1,28 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-04 22:01+0200\n" +"PO-Revision-Date: 2017-06-22 12:56+0000\n" +"Last-Translator: monolifed \n" +"Language-Team: Turkish \n" +"Language: tr\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=n > 1;\n" +"X-Generator: Weblate 2.15-dev\n" + +#: init.lua +msgid "Jukebox" +msgstr "Müzik Kutusu" + +#: init.lua +msgid "Music Disc @1" +msgstr "Müzik Diski @1" diff --git a/mods/furniture/jukebox/locale/zh_Hans.po b/mods/furniture/jukebox/locale/zh_Hans.po new file mode 100644 index 00000000..585a5006 --- /dev/null +++ b/mods/furniture/jukebox/locale/zh_Hans.po @@ -0,0 +1,29 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2017-06-04 22:01+0200\n" +"PO-Revision-Date: 2017-07-03 03:24+0000\n" +"Last-Translator: Muhammad Nur Hidayat Yasuyoshi " +"\n" +"Language-Team: Chinese (Simplified) " +"\n" +"Language: zh_Hans\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=1; plural=0;\n" +"X-Generator: Weblate 2.16-dev\n" + +#: init.lua +msgid "Jukebox" +msgstr "点唱机" + +#: init.lua +msgid "Music Disc @1" +msgstr "音乐光盘 @1"