Noob questions
Moderator: Forum Moderators
Noob questions
Hi, I am learning to prepare an add on to be translated. I learned to use predefined gettext files like #wenoth-units, but I have doubts about if they can be used to translate strings like:
_"ranged drain"
_"melee markaman"
_"forest movement"
_"Poison" (the initial cap gives me problems)
Thanks in advance for help.
_"ranged drain"
_"melee markaman"
_"forest movement"
_"Poison" (the initial cap gives me problems)
Thanks in advance for help.
Be aware English is not my first language and I could have explained bad myself using wrong or just invented words.
World Conquest II
World Conquest II
Re: Noob questions
The initial cap shouldn't be a problem. Gettext doesn't really care, except for that _"poison" and _"Poison" are two different strings.
I don't know how the textdomain for add-ons is defined and which script collects the strings for translation. Maybe looking at a similar add on will help.
I don't know how the textdomain for add-ons is defined and which script collects the strings for translation. Maybe looking at a similar add on will help.
Re: Noob questions
I don't know what you're asking exactly.
If you have this:
Then the translation for "Troll" will be taken from #wesnoth-units, and the translation for "Orc" (and any subsequent strings) from #wesnoth-mytextdomain. There's nothing more to it than that.
EDIT: Added the missing "textdomain"s to the example...
If you have this:
Code: Select all
#textdomain wesnoth-units
_"Troll"
#textdomain wesnoth-mytextdomain
_"Orc"
EDIT: Added the missing "textdomain"s to the example...
Re: Noob questions
It's not an answer to your question, but I guess 'markaman' should be 'marksman', right?
Author of Antar, Son of Rheor ( SP Campaign) | Development Thread + Feedback Thread + Replays of ASoR
Re: Noob questions
I am already usin #textdomain wesnoth-units correctly for tranlate units names; my main doubt was that I was using "ranged drain" to indicate that unit gains drain to all attacks range ranged (wich I dont know if is the best English way to write it, btw). In my language (Spanish), the order of words would change in translation, so I imagine I can´t translate separately each word, so have doubts if is there a translation for the whole text.zookeeper wrote:I don't know what you're asking exactly.
If you have this:Then the translation for "Troll" will be taken from #wesnoth-units, and the translation for "Orc" (and any subsequent strings) from #wesnoth-mytextdomain. There's nothing more to it than that.Code: Select all
#textdomain wesnoth-units _"Troll" #textdomain wesnoth-mytextdomain _"Orc"
EDIT: Added the missing "textdomain"s to the example...
And sorry for write wrong marksman
Be aware English is not my first language and I could have explained bad myself using wrong or just invented words.
World Conquest II
World Conquest II
Re: Noob questions
I am getting translated "Fearless", "Healthy" and "Poison" (that´s all). But I am not getting translated a lot of other abilities like "Teleport"... while I can get translated "teleport"GunChleoc wrote:The initial cap shouldn't be a problem. Gettext doesn't really care, except for that _"poison" and _"Poison" are two different strings.
I don't know how the textdomain for add-ons is defined and which script collects the strings for translation. Maybe looking at a similar add on will help.
Be aware English is not my first language and I could have explained bad myself using wrong or just invented words.
World Conquest II
World Conquest II
Re: Noob questions
Ths means that "teleport" has been translated in the text domain you chose and "Teleport" hasn't. For the translation system, they are two completely different strings.
Re: Noob questions
I am not sure your problem exactly, but you may need to take a look this file?here on this forum to take a look.
You can download all others Fate of a Princess/feedback thread: "What is in own heart that is the most important, not who you are."
Drake Campaign: Brave Wings/feedback thread, Naga Campaign: Return of the Monster, Saurian Campaign: Across the Ocean
Northern Forces - now on 1.12 server
Drake Campaign: Brave Wings/feedback thread, Naga Campaign: Return of the Monster, Saurian Campaign: Across the Ocean
Northern Forces - now on 1.12 server
Re: Noob questions
One last question, if I have the same string writed several times in my add on, would define a macro for that string become translators work easier, or it doesn´t matters and would be an useless effort?
Be aware English is not my first language and I could have explained bad myself using wrong or just invented words.
World Conquest II
World Conquest II
Re: Noob questions
It doesn't matter. You can use the same string as many times as you want inside the same textdomain and it'll still show up only once to translators.
Re: Noob questions
My campaign is under development and will have changes in flavor text, so I guess is not good idea upload it as translatable. However I would like translate myself some of the "info" text to Spanish and French. I downloaded Poedit and gettext, but understand how to create a po file is beyond my skills/time available. In case it was a few minutes task... could someone very kindly create es and fr po-files for me?
- Attachments
-
- World_Conquest_tek.rar
- (82.6 KiB) Downloaded 406 times
Be aware English is not my first language and I could have explained bad myself using wrong or just invented words.
World Conquest II
World Conquest II
Re: Noob questions
Here you have.
Two notes: never have filenames containing spaces (there is a file called "Read me.txt", rename that) and the name of the textdomain should be prefixed by 'wesnoth-'.
Two notes: never have filenames containing spaces (there is a file called "Read me.txt", rename that) and the name of the textdomain should be prefixed by 'wesnoth-'.
Re: Noob questions
Thanks a lot trewe, I will follow your advises
Be aware English is not my first language and I could have explained bad myself using wrong or just invented words.
World Conquest II
World Conquest II
Re: Noob questions
In my noobinesh i thought all I needed was a po file to have a translation working... But I have translated 1 string in po file to test and copied it in my_campaign/translations/es/LC_MESSAGES without get it translated in game. Do I have skiped some basic steps to have translation working or is my mistake more subtle?
Of course I have this in _main And I guess I declared well text domains as I got mainline translations working.
Of course I have this in _main
Code: Select all
[textdomain]
name="wesnoth-World_Conquest_tek_translated"
path="data/add-ons/World_Conquest_tek_translated/translations"
[/textdomain]
- Attachments
-
- World_Conquest_tek_translated.rar
- (611.39 KiB) Downloaded 387 times
Be aware English is not my first language and I could have explained bad myself using wrong or just invented words.
World Conquest II
World Conquest II