I18N

Content and general development discussion, including quest scripts and server code. TMW Classic is a project comprising the Legacy tmwAthena server & the designated improved engine server based on evolHercules.


Forum rules

This forum houses many years of development, tracing back to some of the earliest posts that exist on the board.

Its current use is for the continued development of the server and game it has always served: TMW Classic.

Post Reply
Siegfried
Novice
Novice
Posts: 60
Joined: 03 Jun 2013, 20:03

I18N

Post by Siegfried »

Hi,

may i suggest a modification to the xml files? It's about all xml files, it is a minor change, but there would be a big advantage.

Generally: Currently anything is an attribute. Suggestion: Move all attributes with translatable text to child nodes.

Example for items.xml.

Currently:

Code: Select all

<item id="501"
        image="use/potions/a.png|G:#22ff22"
        name="Cactus Drink"
        description="A fresh drink."
        effect="+15 HP"
        type="usable"
        hp="15"
        weight="4"
        max-per-slot="10"/>
Suggested:

Code: Select all

<item id="501"
        image="use/potions/a.png|G:#22ff22"
        effect="+15 HP"
        type="usable"
        hp="15"
        weight="4"
        max-per-slot="10">
        <name>Cactus Drink</name>
       <description>A fresh drink</description>
</item>
Why? Well, consider this:

Code: Select all

<item id="501"
        image="use/potions/a.png|G:#22ff22"
        effect="+15 HP"
        type="usable"
        hp="15"
        weight="4"
        max-per-slot="10">
        <name xml:lang="en">Cactus Drink</name>
        <description xml:lang="en">A fresh drink</description>
        <description xml:lang="de">Ein erfrischendes Getränk</description>
        <name xml:lang="de">Kaktus Getränk</name>
</item>
The xml:lang attribute is a general xml attribute and does not need to be declared in any schema. Just use it and your're done.

There may be a "default" language, if you add this attribute to f.ex. the root element. If you add

Code: Select all

<items xml:lang="en">
...
</items>
Then you may write an item like this:

Code: Select all

<item id="501"
        image="use/potions/a.png|G:#22ff22"
        effect="+15 HP"
        type="usable"
        hp="15"
        weight="4"
        max-per-slot="10">
        <name>Cactus Drink</name>
        <description>A fresh drink</description>
        <description xml:lang="de">Ein erfrischendes Getränk</description>
        <name xml:lang="de">Kaktus Getränk</name>
</item>
Advantage is obvious :)
4144
Knight
Knight
Posts: 965
Joined: 03 Aug 2009, 11:57

Re: I18N

Post by 4144 »

items.xml can be translated without this changes. See program "itstool".
Also this changes hardening work for translators. always need extract other languages to separate files for translation and after merging it back.
4144
Knight
Knight
Posts: 965
Joined: 03 Aug 2009, 11:57

Re: I18N

Post by 4144 »

btw if you want add support for translation xml files in German server, you already can for ManaPlus.
In The Mana World people against translations :(
But Evol Online using translations.
Siegfried
Novice
Novice
Posts: 60
Joined: 03 Jun 2013, 20:03

Re: I18N

Post by Siegfried »

Well, these are client side translations, aren't they? But nevertheless im interested in how to.
4144 wrote: In The Mana World people against translations :(
What a pity.
4144 wrote: But Evol Online using translations.
Good idea :) I'll take a closer look at it. I have tried to set up a local server but didn't succeed. And since GoNzo is currently working on moving germantmw from eAthena to ManaServ, and germantmw does indeed need a refresh, maybe we implement that there.

BTW, it is not harder to translate. If you really have to put the translation into a separate file, this could be merged automatically with the help of xsl. But better would be to keep it in one file and translate it there. Different translations could be merged automatically with xsl. At least as long as there are no conflicts :)

If necessary i could write the xsl files for that. If merging on Linux use xsltproc, on Windows use msxsl. Both should work.
4144
Knight
Knight
Posts: 965
Joined: 03 Aug 2009, 11:57

Re: I18N

Post by 4144 »

Siegfried wrote:Good idea :) I'll take a closer look at it. I have tried to set up a local server but didn't succeed. And since GoNzo is currently working on moving germantmw from eAthena to ManaServ, and germantmw does indeed need a refresh, maybe we implement that there.

BTW, it is not harder to translate. If you really have to put the translation into a separate file, this could be merged automatically with the help of xsl. But better would be to keep it in one file and translate it there. Different translations could be merged automatically with xsl. At least as long as there are no conflicts :)

If necessary i could write the xsl files for that. If merging on Linux use xsltproc, on Windows use msxsl. Both should work.
Yes this is client side tranlsation, because items names/description using only client.

Better use eAthena, manaserv still in early stage, they always rewriting it.
Also ManaPlus cant work with manaserv and will not work with it, this mean all translation support you must create from scratch.

If you want ask about manaserv, better do this in manasource sub forum.
Siegfried
Novice
Novice
Posts: 60
Joined: 03 Jun 2013, 20:03

Re: I18N

Post by Siegfried »

Well, translations of UI parts do fit perfectly on client side. But translations of server provided things like items, skill names and so on would be better done on server side.

The server already transmits the xml files to the client. Optionally only a part of it. This way the client could get the translations of the server provided objects from the server.
User avatar
o11c
Grand Knight
Grand Knight
Posts: 2262
Joined: 20 Feb 2011, 21:09
Location: ^ ^

Re: I18N

Post by o11c »

The reason translation works for Evol but not for TMW is that TMW has a LOT more content. It would be simply impossible to keep all the translations up-to-date.

However, I do have ideas for translation in a toy environment. But it's not a high priority, given how impractical translation will always be, and how many more important things there are to worry about.
Former programmer for the TMWA server.
User avatar
WildX
Source of Mana
Source of Mana
Posts: 2085
Joined: 07 Aug 2010, 14:13
Location: United Kingdom
Contact:

Re: I18N

Post by WildX »

o11c wrote:The reason translation works for Evol but not for TMW is that TMW has a LOT more content. It would be simply impossible to keep all the translations up-to-date.

However, I do have ideas for translation in a toy environment. But it's not a high priority, given how impractical translation will always be, and how many more important things there are to worry about.
I support Evol 100%, but I agree that it supports way too many languages and it's going to be hell to keep all of them up to date as the game evolves (no pun intended :P ). However, providing support in TMW for just a few popular languages like Spanish, Portoguese and German could be possible even with a lot of content and it could discourage language-specific servers that take away a lot of players from the main server and divide the community. If people who don't speak english well enough could read quests and things like that in their own language, maybe they would feel less threatened by the challenge of being in an english speaking environment and make an effort to, you know, follow rule 5 instead of leaving the server because of it.

TMW Team member

User avatar
Jaxad0127
Manasource
Manasource
Posts: 4209
Joined: 01 Nov 2007, 17:35
Location: Internet

Re: I18N

Post by Jaxad0127 »

A quick look at the translation effort on the wiki. These are the number of articles in each language that use the I18n template (the one that provides language links):
English: 177
Spanish: 66
Portuguese: 10
German 20
French: 147

I make no claims about pages being up to date, or even vaguely correct.
Image
User avatar
Reid
Lead Developer (SoM)
Lead Developer (SoM)
Posts: 1551
Joined: 15 May 2010, 21:39
Location: Artis
Contact:

Re: I18N

Post by Reid »

.:WildX:. wrote:
o11c wrote:The reason translation works for Evol but not for TMW is that TMW has a LOT more content. It would be simply impossible to keep all the translations up-to-date.

However, I do have ideas for translation in a toy environment. But it's not a high priority, given how impractical translation will always be, and how many more important things there are to worry about.
I support Evol 100%, but I agree that it supports way too many languages and it's going to be hell to keep all of them up to date as the game evolves (no pun intended :P ). However, providing support in TMW for just a few popular languages like Spanish, Portoguese and German could be possible even with a lot of content and it could discourage language-specific servers that take away a lot of players from the main server and divide the community. If people who don't speak english well enough could read quests and things like that in their own language, maybe they would feel less threatened by the challenge of being in an english speaking environment and make an effort to, you know, follow rule 5 instead of leaving the server because of it.
TMW and Evol have a different understanding and written rule of which language to speak in public, on Evol we encourage peoples to speak their own language if they're alone and talking the same language and also if they wish to. On TMW this right is forbidden, so adding a multi-language support would just open more warns & kicks. :)
"Time is an illusion. Lunchtime doubly so."
-- Ford Prefect
User avatar
WildX
Source of Mana
Source of Mana
Posts: 2085
Joined: 07 Aug 2010, 14:13
Location: United Kingdom
Contact:

Re: I18N

Post by WildX »

Reid wrote:
.:WildX:. wrote:
o11c wrote:The reason translation works for Evol but not for TMW is that TMW has a LOT more content. It would be simply impossible to keep all the translations up-to-date.

However, I do have ideas for translation in a toy environment. But it's not a high priority, given how impractical translation will always be, and how many more important things there are to worry about.
I support Evol 100%, but I agree that it supports way too many languages and it's going to be hell to keep all of them up to date as the game evolves (no pun intended :P ). However, providing support in TMW for just a few popular languages like Spanish, Portoguese and German could be possible even with a lot of content and it could discourage language-specific servers that take away a lot of players from the main server and divide the community. If people who don't speak english well enough could read quests and things like that in their own language, maybe they would feel less threatened by the challenge of being in an english speaking environment and make an effort to, you know, follow rule 5 instead of leaving the server because of it.
TMW and Evol have a different understanding and written rule of which language to speak in public, on Evol we encourage peoples to speak their own language if they're alone and talking the same language and also if they wish to. On TMW this right is forbidden, so adding a multi-language support would just open more warns & kicks. :)
There's already an amendment spree waiting to happen on TMW, just give it time :p

TMW Team member

Siegfried
Novice
Novice
Posts: 60
Joined: 03 Jun 2013, 20:03

Re: I18N

Post by Siegfried »

Well, i can understand the pros and cons. Basically to translate or not translate is a decision of the maintainers.

But: If the data format enables translation, this is a real decision. Other server maintainers might decide different. But if there is no such option, there is no decision. The freedom to decide what to do requires the technical prerequisites :)

To keep it technically: Moving all translatable string attributes to child nodes does not mean, that these strings have to be translated. If for TMW it is desired to keep everything in english, well, why not. But having the option geves you the freedom to do it or not do it.
4144
Knight
Knight
Posts: 965
Joined: 03 Aug 2009, 11:57

Re: I18N

Post by 4144 »

Siegfried wrote:Well, i can understand the pros and cons. Basically to translate or not translate is a decision of the maintainers.

But: If the data format enables translation, this is a real decision. Other server maintainers might decide different. But if there is no such option, there is no decision. The freedom to decide what to do requires the technical prerequisites :)

To keep it technically: Moving all translatable string attributes to child nodes does not mean, that these strings have to be translated. If for TMW it is desired to keep everything in english, well, why not. But having the option geves you the freedom to do it or not do it.
For now in ManaPlus you can use *.po files in directory "translations" in client data and it will be used in all places where possible.
Post Reply