1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Translations

Discussion in 'Communitas Expansion Pack' started by Thalassicus, Jan 3, 2013.

  1. Thalassicus

    Thalassicus Bytes and Nibblers

    Joined:
    Nov 9, 2005
    Messages:
    11,057
    Location:
    Texas
    I'm working on a major overhaul of the text files to make translations easier. I need help testing this, since I only have the English language version.

    There are two ways to handle outdated translations:

    A. Show correct information in the wrong language.
    B. Show wrong information in the correct language.

    Wrong information makes the game unplayable, so I'm designing the new system to present the most recent information (option B), even if it must do so in English. If a local language file says a policy gives 2:c5production: in Deutsch, and that later changes to 1:c5production: in the English version, the game will show the more recent English version. I will do this by adding a "date modified" tag for text, and compare the tags to see which is newer.

    ===============

    Update 3: The translation system is ready for early testing.

    The steps basically are:
    1. Copy English to google.
    2. Copy google to table.
    3. Edit language text.
    4. Copy table to file.

    The language codes are:

    Column 1 Column 2 Column 3
    Code Language
    DE_DE Deutsch German
    EN_US English English (US)
    ES_ES Español Spanish
    FR_FR Français French
    IT_IT Italiano Italian
    JA_JP Nihongo Japanese
    PL_PL Polski Polish
    RU_RU Russkij Jazyk Russian
    ZH_CN Zhōngwén Chinese


    ==

    Detailed Instructions
    Spoiler Instructions :

    1. Click to install notepad++.
    2. Click to install Civup and Gem, then find the GEM_Language table in the GEM mod folder here:

    \Documents\My Games\Sid Meier's Civilization 5\MODS

    3. Open the Research tab of the GEM_Language table (or any tab you want to translate):

    Spoiler :


    4. Copy the English "Date" and "EN_US" text columns.
    Spoiler :


    5. Paste in your language section. I am using Russian in this example.
    Spoiler :


    6. Copy your language text.
    Spoiler :


    7. Paste on translate.google.com. Set your language.
    Spoiler :


    8. Select the translated text, then copy.
    Spoiler :


    9. Paste in your language section of the table.
    10. Edit any text which translated wrong, and save the table.
    Spoiler :


    11. Copy the green column with "INSERT INTO" text from your language section.
    Spoiler :


    12. Open the GEM/Text/Research.sql file with notepad++.
    Spoiler :


    13. Paste the text.
    Spoiler :


    14. Save the file as "Language_(your language code).sql"
    Spoiler :

    15. Repeat steps 1-14 for the other tabs of the GEM_Language table, or Civup_Language table, if you wish to translate the whole project.

    16. Start a thread on Civfanatics to upload the file.
    17. Compress the file(s) to a zip.
    Spoiler :


    18. Upload the zip file, and post.
    Spoiler :
     
  2. mitsho

    mitsho Deity

    Joined:
    Nov 3, 2003
    Messages:
    7,252
    Location:
    Europe, more or less
    Ha, funny, that was just the discussion in the other German forum ;) (or rather, someone mentioned it).

    I agree it's better to have a scrambled half English - half German version than one with wrong information.

    It's difficult to do a translation of a mod that is still changing regularly but I guess, there's nothing around that in the end..
     
  3. Thalassicus

    Thalassicus Bytes and Nibblers

    Joined:
    Nov 9, 2005
    Messages:
    11,057
    Location:
    Texas
    Here is a preview of my new design. I hope to complete this by tomorrow. Let's say someone called Alice wants to translate GEM into Spanish. She begins by setting a new LANGUAGE option to ES_ES (Espanol) in the Civup Options.sql file:



    Alice now opens a new Language table which contains all translations. She copies the English to Google's machine translation page, then copies the Spanish back. This saves her time with a basic starting point for the Spanish:

    Spoiler :






    Alice can now check the Spanish to fix mistakes with the automatic machine translation. Once she is happy with the translation, the table automatically creates data for Civ V. Alice copies that data to a file in the GEM folder:

    Spoiler :




    Once she completes these steps, the new Spanish text shows in Civ 5. The most recent text will always display (English or Spanish). If I later change the English text for the "RECRUITMENT" civilopedia entry, it will override older translations for that one text entry. The Language table will have a section for every language.
     
  4. Johnny Deacon

    Johnny Deacon Chieftain

    Joined:
    Dec 27, 2012
    Messages:
    36
    Location:
    Colombia

    That's awesome man! it will help me a lot with the translations of your mods... Thanks again for taking time doing this!

    I will appreciate it

    But a pair of Question:

    If I insert changes in civilopedia, it only affects when playing the mod isn't it?

    This application is for everyone to do their own translations? or once I add the official translations of your mod, as these will be official until a new term is added by you?

    I guess second option is the appropiate.
     
  5. Thalassicus

    Thalassicus Bytes and Nibblers

    Joined:
    Nov 9, 2005
    Messages:
    11,057
    Location:
    Texas
    This will only affect players using the Civup or Gem mods. However, it will be easy for other modders to use the system I am designing.

    If you give me Spanish translations, they will be the "official" translations visible to Spanish players of the mod. Someone could later send me new Spanish translations to add to the "official" version.


    If this English is added on January 3:
    'TECH_RECRUITMENT' 2013-1-03 'Training'

    You can add Spanish on January 4, and send it to me:
    'TECH_RECRUITMENT' 2013-1-04 'Formación'

    All Spanish players will see "Formación". It will only show English if I later change that term to something new like:
    'TECH_RECRUITMENT' 2013-1-05 'Recruitment'

    Then someone else might send me a new translation for Spanish:
    'TECH_RECRUITMENT' 2013-1-06 'Reclutamiento'


    I completed the basic framework. I am now creating code to detect which version of text is more recent.
     
  6. Johnny Deacon

    Johnny Deacon Chieftain

    Joined:
    Dec 27, 2012
    Messages:
    36
    Location:
    Colombia
    Great, Waiting for that ;)


    PS: I think it is easy to translate if I compare the tags in the original xml and only change the values that affects of course I know that there are unique tags in your mods but the work will be less I guess
     
  7. mitsho

    mitsho Deity

    Joined:
    Nov 3, 2003
    Messages:
    7,252
    Location:
    Europe, more or less
    Well I guess that means I need to really do it this time ;) But not in January, I'm occupied with other stuff right now... ;)

    :goodjob:
     
  8. Thalassicus

    Thalassicus Bytes and Nibblers

    Joined:
    Nov 9, 2005
    Messages:
    11,057
    Location:
    Texas
    I got sidetracked updating the wiki website today, so I'll finish this up tomorrow. :)
     
  9. Thalassicus

    Thalassicus Bytes and Nibblers

    Joined:
    Nov 9, 2005
    Messages:
    11,057
    Location:
    Texas
    I completed part of the process, which is ready for testing in post #1. Please ask if you have any questions while testing.
     
  10. Johnny Deacon

    Johnny Deacon Chieftain

    Joined:
    Dec 27, 2012
    Messages:
    36
    Location:
    Colombia
    Good, I will work on it tomorrow and post the translations.
     
  11. Johnny Deacon

    Johnny Deacon Chieftain

    Joined:
    Dec 27, 2012
    Messages:
    36
    Location:
    Colombia
  12. Thalassicus

    Thalassicus Bytes and Nibblers

    Joined:
    Nov 9, 2005
    Messages:
    11,057
    Location:
    Texas
    It worked! I am glad. I finished moving all text to the two language files, and attached them to post #1. You can start translating the rest if you want. I expect to have this finished by Friday January 11.
     
  13. Thalassicus

    Thalassicus Bytes and Nibblers

    Joined:
    Nov 9, 2005
    Messages:
    11,057
    Location:
    Texas
    Do not translate promotion text yet. I am working on something which will make translating promotions easier. The promotion text will join together small pieces to form sentences, like how unit and building tooltips form.
     
  14. Johnny Deacon

    Johnny Deacon Chieftain

    Joined:
    Dec 27, 2012
    Messages:
    36
    Location:
    Colombia
    Excellent! I'll get it. Moreover, I believe that this translation will take a long time because I'll do it in my idle hours during work or at home. When it will be ready I will send you.
     
  15. Thalassicus

    Thalassicus Bytes and Nibblers

    Joined:
    Nov 9, 2005
    Messages:
    11,057
    Location:
    Texas
    Do not hurry, it will take time for me to get everything finished. Hopefully, the automatic translations of google will help make it faster, then you can improve the results. :)
     
  16. Piruparka

    Piruparka Prince

    Joined:
    May 1, 2010
    Messages:
    564
    Gender:
    Male
    Location:
    Germany
    That's cool, I think I will look into this and translate to German soon, in case ppl are interested. My translation would not base on google translator but - since I'm German - be more qualified :D
     
  17. Gothic_Empire

    Gothic_Empire AKA, Ramen Empire

    Joined:
    Aug 5, 2008
    Messages:
    1,493
    我说汉语; 我很高兴帮你。
    I speak chinese; I'd be happy to help.
     
  18. Thalassicus

    Thalassicus Bytes and Nibblers

    Joined:
    Nov 9, 2005
    Messages:
    11,057
    Location:
    Texas
    The update today includes the first version of this new translation system. Civup and Gem each contain a Language.xml table in their mod folders. You can follow the instructions in post #1 to translate these files.

    I estimate translating the project into a language would take about 30 minutes with the Google machine translator. I do not know how long it would take for a more accurate human translation. Human translation is obviously best if you can do that.

    Did I spell the name of each language correctly:

    Column 1 Column 2 Column 3
    Code Language
    DE_DE Deutsch German
    EN_US English English (US)
    ES_ES Español Spanish
    FR_FR Français French
    IT_IT Italiano Italian
    JA_JP 日本語 Japanese
    PL_PL Polski Polish
    RU_RU ру́сский язы́к Russian
    ZH_CN 简体字 Chinese (Simplified)
     
  19. Johnny Deacon

    Johnny Deacon Chieftain

    Joined:
    Dec 27, 2012
    Messages:
    36
    Location:
    Colombia
    Bold Question: A lot of time I tell you. . . google translate to spanish very imprecise.

    I'm almost done, I've had a lot of work these days, I hope to finish it next week
     
  20. Thalassicus

    Thalassicus Bytes and Nibblers

    Joined:
    Nov 9, 2005
    Messages:
    11,057
    Location:
    Texas
    Take your time. :)
     

Share This Page