[Minetest Game] Language translation for single-player worlds

Post Reply
gibberish_1
New member
Posts: 2
Joined: Wed Aug 27, 2025 13:16

[Minetest Game] Language translation for single-player worlds

by gibberish_1 » Post

I want to make a language translation for Minetest Game. Specifically for personal use within my single-player worlds. It's basically just a fantasy conlang (constructed language). Is there any way I can do this without needing to make a translation for the whole Luanti system?

So Luanti remains the language its been set to (in this case, English). While in Minetest Game, all of the blocks, items, mobs, and UI are the in the language I've translated.

I know how to make .tr files for each of the mods using the templates. Is there any way that I could conveniently switch the translated language on and off in-game?

User avatar
Blockhead
Moderator
Posts: 2787
Joined: Wed Jul 17, 2019 10:14
GitHub: Montandalar
IRC: Blockhead256
In-game: Blockhead Blockhead256
Location: Land Down Under
Contact:

Re: [Minetest Game] Language translation for single-player worlds

by Blockhead » Post

I can't see how this would work without a mod, or in fact editing Minetest Game itself. As you have discovered, the program of Luanti can't switch languages without restarting, nor do you really want to switch the whole program, just your modded game.

It would not be a very good software pattern, but, you could do this by making a mod and making sure it loads first by making all the mods in MTG depend on it (or make it the first mod in game.conf that overrides core.get_translator^, and returns a function that fetches your own language (or an obscure language you don't mind overriding, like maybe lojban) with core.get_translated_string. In this mod's settingtypes.txt, you could even configure the language code of the language that is meant to be loaded instead.

^minetest is the same table, so override of one does the other; Minetest Game still mostly uses minetest.* because of its age.
/˳˳_˳˳]_[˳˳_˳˳]_[˳˳_˳˳\ Advtrains enthusiast | My map: Noah's Railyard | My Content on ContentDB ✝️♂

yw05
Member
Posts: 451
Joined: Tue May 07, 2019 12:59
GitHub: y5nw
IRC: y5nw
Location: Germany

Re: [Minetest Game] Language translation for single-player worlds

by yw05 » Post

gibberish_1 wrote:
Wed Aug 27, 2025 14:51
Is there any way I can do this without needing to make a translation for the whole Luanti system?

So Luanti remains the language its been set to (in this case, English). While in Minetest Game, all of the blocks, items, mobs, and UI are the in the language I've translated.
If a translated string is not available, the original string (which is generally written in English) is used; there is no need (as in: technical requirement) to make a translation for the whole "Luanti system" (whatever it is), and translations often do not reach full coverage.
I know how to make .tr files for each of the mods using the templates.
If you want to implement this by only overriding/reusing an "obscure" language code (as Blockhead mentioned) for which MTG does not provide translations, you only need to provide the translation files and then set the client to use that language. The translation files can simply be included in a different mod (which, in this case, does not require the overrides mentioned by Blockhead). Note that this will also use the language for the engine and other mods than MTG.

(Less related: older versions of Luanti included the language code yue for Cantonese, but it was removed at some point because the translation file for the engine was practically empty.)
Is there any way that I could conveniently switch the translated language on and off in-game?
No.

User avatar
Wuzzy
Member
Posts: 5038
Joined: Mon Sep 24, 2012 15:01
GitHub: Wuzzy2
IRC: Wuzzy
In-game: Wuzzy
Contact:

Re: [Minetest Game] Language translation for single-player worlds

by Wuzzy » Post

It's hacky, but I believe you could add a mod that contains a locale folder which just adds all *.tr files for every mod in the language you normally use in Luanti. This is because mod-provided files normally take precedence over game-provided files if both game and mod include a file with the same name. For example:

Code: Select all

mymod/
  locale/
    default.qqq.tr
    flowers.qqq.tr
    stairs.qqq.tr
    ...
(qqq = language code your normally use in Luanti)

"Turning on or off" then just means turning on or off the mod.

I haven't tested this theory tho.

May I ask which language it is or is this a secret? :D

User avatar
kuboid
Member
Posts: 38
Joined: Thu Jan 30, 2020 19:59
IRC: kuboid
In-game: kuboid

Re: [Minetest Game] Language translation for single-player worlds

by kuboid » Post

I'm also interested in your custom game language, I also had this thought before.
Maybe you could make a project out of it? After Elbish and Klingon, why not have a Luantish Minish or Testish? :-)

gibberish_1
New member
Posts: 2
Joined: Wed Aug 27, 2025 13:16

Re: [Minetest Game] Language translation for single-player worlds

by gibberish_1 » Post

Wuzzy wrote:
Wed Sep 10, 2025 07:19
It's hacky, but I believe you could add a mod that contains a locale folder which just adds all *.tr files for every mod in the language you normally use in Luanti. This is because mod-provided files normally take precedence over game-provided files if both game and mod include a file with the same name. For example:

Code: Select all

mymod/
  locale/
    default.qqq.tr
    flowers.qqq.tr
    stairs.qqq.tr
    ...
(qqq = language code your normally use in Luanti)

"Turning on or off" then just means turning on or off the mod.

I haven't tested this theory tho.

May I ask which language it is or is this a secret? :D
Hello, sorry for the late reply! To be honest I lost interest and kinda forgot about this project the past few months. I will keep this info in mind though.

The language I wanted to use is called Gargish/gargl. Which is the language spoken by gargoyles in the Ultima CRPG series. It has a wiki page here.

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests