Topic: I am lost
Atanase Topic Opener |
Posted at: 2021-04-17, 09:28
Hello, No, not as much lost as that. Just a certain dichotomy between two languages. I am preparing a scenario where there must be explanatory texts. I think these texts in French, I prepare my text in French, I translate the text in English to put it in the text.lua file and I run the game to see if the displays correspond to my expectations. Of course the text that appears is in English and I have to make a big effort to find where I am in the scenario. All this being explained, is it possible that I start using a .mo file which would allow me to have the texts in French. If so, where should I put it and under which directory? Otherwise I will have to separate my brain in two, a French part, an English part. I'm afraid I won't endure this operation long before I'm going crazy. La connaissance ne vaut que si elle est partagée par le plus grand nombre. |
Nordfriese |
Posted at: 2021-04-17, 12:05
The .mo file goes in
(where you can replace
at the start of your scenario's Top Quote |
Atanase Topic Opener |
Posted at: 2021-04-17, 17:59
Thank you, I will keep my sanity. Just a little thing, looking at the 'init.lua' of other scenarii I found 'set_textdomain' instead of 'push textdomain'. Does it make a fundamental difference? La connaissance ne vaut que si elle est partagée par le plus grand nombre. |
Nordfriese |
Posted at: 2021-04-17, 18:37
Top Quote |
Atanase Topic Opener |
Posted at: 2021-04-17, 20:03
Ok, I change. When I have to learn a new language, I always take inspiration from what has been written before, I don't necessarily read all the documentation from A to Z, especially if it is only in English. La connaissance ne vaut que si elle est partagée par le plus grand nombre. |
Atanase Topic Opener |
Posted at: 2021-04-17, 23:31
Oups,
La connaissance ne vaut que si elle est partagée par le plus grand nombre. |
Nordfriese |
Posted at: 2021-04-18, 12:34
Perhaps you're using an outdated Widelands version, which does not have these functions yet? If you want to write the scenario specifically for this older version, just use
Btw "addon" is just the name of a parameter so the complete function call is actually
You only need to set the second parameter if you want to package your mission as an add-on. Top Quote |
Atanase Topic Opener |
Posted at: 2021-04-18, 15:13
I use build21-26.14 I don't know if it is a very old version but it is the last version I found in the openSuse repository. If there is a new stable version somewhere I'm ready to install it. Ok for the term "addon", I haven't understand. PS: I had never seen a line from Lua before last week, I don't know how to interpret error messages yet. La connaissance ne vaut que si elle est partagée par le plus grand nombre. |
Nordfriese |
Posted at: 2021-04-18, 15:45
Build21 is the most recent stable release (published 2020-07-18) – it's too easy to forget the pace at which development happens The next stable release (Widelands 1.0) will be published this spring. It contains a number of major changes to the Lua API, with the intention to offer a more stable (and forward-compatible) API from version 1.0 onwards. Note that our online documentation always refers to the most recent development version; it is assumed and recommended that most people who develop game content will be using the latest state-of-the-art rather than a stable release. Top Quote |
Atanase Topic Opener |
Posted at: 2021-04-18, 15:57
I understand very well, but ... Please let me some time to be at the top and to use the "latest state-of-the-art" release. I risk having enough problems with a language that I do not yet master (Lua) without taking the risk of having the errors of an unstable version. Soon, very soon, I promise you that I will upgrade to the latest version stable or not. La connaissance ne vaut que si elle est partagée par le plus grand nombre. |