Jump to content


Photo

Translating the TDM GUI


  • Please log in to reply
488 replies to this topic

#476 Tels

Tels

    Mod hero

  • Member
  • PipPipPipPipPip
  • 15024 posts

Posted 17 December 2014 - 01:54 PM

Oh, one more thing: Is it enough if I just edit the slovak.lang file ?


No, the xyz.lang files are generated automatically from the all.lang file (they need to be in the right encoding and a script checks all entries).

Please only edit all.lang :)

Looking at it now in Notepad++, I can clearly see where the few auto-translated lines are from, while the vast majority of the text is still in English.

As a test run of the translated file, I'll write the GUI features without diacritics at first, then eventually add them once I consult the wiki in a more in-depth way. I want to avoid more serious problems with unrecognised letters.


That sounds good :)

For testing, you can also edit the slovak.lang file - afterwards I would then have to merge the changes back into all.lang. It is certainly doable, but more work :)

Thank you in advance!
"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man." -- George Bernard Shaw (1856 - 1950)

"Remember: If the game lets you do it, it's not cheating." -- Xarax

#477 Petike the Taffer

Petike the Taffer

    Member

  • Member
  • PipPip
  • 436 posts

Posted 17 December 2014 - 06:47 PM

Ah, thank you, now I get the gist of it. Personally, I would have preferred if I could have fiddled around with the specific language file, but as long as I can get it to work via the "all" file as well, I don't mind. I would have preferred to work on that specific language file for safety reasons: Even if I mess up something in "all", I won't have to keep constantly replacing it with a backup copy again, just to get things working. Either way, I'm sure I'll get the hang of it and manage. :)

#478 Tels

Tels

    Mod hero

  • Member
  • PipPipPipPipPip
  • 15024 posts

Posted 19 December 2014 - 08:25 AM

Ah, thank you, now I get the gist of it. Personally, I would have preferred if I could have fiddled around with the specific language file, but as long as I can get it to work via the "all" file as well, I don't mind. I would have preferred to work on that specific language file for safety reasons: Even if I mess up something in "all", I won't have to keep constantly replacing it with a backup copy again, just to get things working. Either way, I'm sure I'll get the hang of it and manage. :)


Just for the translation, you can also work on the specific .lang file, if that is easier. It has then to be merged back in by me, but that is certainly doable.

One thing to watch our for are comments - the all.lang file often contains hints for translators, while the autogenerated .lang file misses these, so if you are unsure about the translation, look into the all.lang file - or ask here :)

Thank you!
"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man." -- George Bernard Shaw (1856 - 1950)

"Remember: If the game lets you do it, it's not cheating." -- Xarax

#479 Petike the Taffer

Petike the Taffer

    Member

  • Member
  • PipPip
  • 436 posts

Posted 12 January 2015 - 03:39 PM

I've gotten back to this and as I'd like to test how my translated text looks like, I need to ask: Is there some handy .pk4 packing utility lying around somewhere, or do I need to install DarkRadiant to do that kind of thing ?



#480 rich_is_bored

rich_is_bored

    Advanced Member

  • Member
  • PipPipPip
  • 886 posts

Posted 13 January 2015 - 03:20 AM

PK4 files are simply zip archives that have been renamed.



#481 Tels

Tels

    Mod hero

  • Member
  • PipPipPipPipPip
  • 15024 posts

Posted 14 January 2015 - 05:05 AM

I've gotten back to this and as I'd like to test how my translated text looks like, I need to ask: Is there some handy .pk4 packing utility lying around somewhere, or do I need to install DarkRadiant to do that kind of thing ?

 

As rich said, they are just ZIP archives. You can also just put the translated texts into the directory structure, the game will always load these files first before looking into PK4s.

 

If you do package a PK4, make sure its name starts with a z, they are loaded in order of reverse alphabetical, so "zzz.pk" is loaded before "tdm:_foo.pk4", which is loaded before "aalglatt.pk4" :)

 

If you have more questions, please ask!


"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man." -- George Bernard Shaw (1856 - 1950)

"Remember: If the game lets you do it, it's not cheating." -- Xarax

#482 Petike the Taffer

Petike the Taffer

    Member

  • Member
  • PipPip
  • 436 posts

Posted 14 January 2015 - 06:38 PM

Well, the thing is, I have the game's original tdm_base01.pk4 zip backed up elsewhere on the disk. I want to test the translation I've done so far by repackaging a different copy of tdm_base01 (the one I've been using for the work), in order to then copy it into the TDM folder, overwrite the original zip and have a look at how the translation came out. Do I really just need to rename my test zip to .pk4 once I repackage it for testing ?

 

I particularly want to test which diacritics might be potentially causing problems. I've read about the various letter and diacritic sets TDM can handle in its current version, but I still want to check to be sure.


Edited by Petike the Taffer, 14 January 2015 - 06:57 PM.


#483 Petike the Taffer

Petike the Taffer

    Member

  • Member
  • PipPip
  • 436 posts

Posted 14 January 2015 - 08:08 PM

Erm, nevermind, I just downloaded a Doom 3 zip-to-pk4/pk4-to-zip converter and it works like a charm.

 

I've copied the English section text in all.lang under the Slovak section and translated the bits I already had prepared (and had previously added erroneously to the slovak.lang file). I've repacked tdm_base01, copied it into the game folder and the translation seems to be working fine.

 

Unfortunately, most of the diacritics in the smaller menu texts don't seem to show up for some reason. And some longer lines for the menu texts didn't seem to register, or I've confused them with their doubles, or some of the letters don't register (possibly Ž, Ď, Ľ, I dunno... I'll have to keep checking.).

 

I do have one problem, though: Once I replaced the slovak.lang file I've tampered with with its original version, much of my translation disappeared. I still have my translation in all.lang, but it isn't registering. Do I need to add something for it to work ? Because right now, almost all I'm getting is the overwriting by that auto-translate script. I can't see my progress due to that.


Edited by Petike the Taffer, 14 January 2015 - 08:20 PM.


#484 New Horizon

New Horizon

    Mod hero

  • Active Developer
  • PipPipPipPipPip
  • 13902 posts

Posted 14 January 2015 - 08:50 PM

A pk4 is a zip.  All that zip to pk4 "converter" is doing is renaming the file extension. :)  Seriously, there is nothing mysterious about pk4's.



#485 Petike the Taffer

Petike the Taffer

    Member

  • Member
  • PipPip
  • 436 posts

Posted 14 January 2015 - 09:15 PM

Now I have a problem with the "gen_lang.pl" script. I'm not sure how to use it and the game almost completely ignores the translated text I've put into the all.lang file. It still has the same badly auto-translated text from before, despite it being gone from both all.lang and slovak.lang. :( I made sure the scripting is arranged in the way it should be, so I don't think the problem's there. :unsure:


Edited by Petike the Taffer, 14 January 2015 - 09:16 PM.


#486 Petike the Taffer

Petike the Taffer

    Member

  • Member
  • PipPip
  • 436 posts

Posted 16 January 2015 - 08:15 PM

Please guys, could you advise me on that script ? I'm nearly finished with my translation in all.lang and I'd like to test out whether it works or not. Just to get an idea of which diacritics and titles will show up fine and which won't. If I can't even test my translation, then my whole effort is quite pointless at the moment. :(



#487 Petike the Taffer

Petike the Taffer

    Member

  • Member
  • PipPip
  • 436 posts

Posted 25 January 2015 - 06:45 PM

Good news, people. B)

 

I've advanced a lot with the translation. There are still many things I need to finish, but now that I can review my work regularly, the whole process has been sped up considerably. :smile:

I have some minor issues with one or two types of letters, but I'll cover that later.



#488 demagogue

demagogue

    Mod hero

  • Active Developer
  • PipPipPipPipPip
  • 5502 posts

Posted 25 January 2015 - 11:03 PM

If I wanted to do Japanese translation, how would I start with the characters?
Posted Image

#489 Tels

Tels

    Mod hero

  • Member
  • PipPipPipPipPip
  • 15024 posts

Posted 30 January 2015 - 12:11 PM

If I wanted to do Japanese translation, how would I start with the characters?

 

I'm not sure how that works. The engine only supports 256 characters, and Japanese would be a multi-byte font? Plus, I'm not even sure we do have fonts for Japanese. Someone might have to look into how D3 handled that.

 

Translating the strings is actually easy, but they would not be used in the engine.


"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man." -- George Bernard Shaw (1856 - 1950)

"Remember: If the game lets you do it, it's not cheating." -- Xarax




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users