Modding Help Content Patcher Dialogue Translation Problems

Discussion in 'Mods' started by glowy, Jun 30, 2018.

  1. glowy

    glowy Title Not Found

    Hello! I'm the author of the dialogue mods Doki Doki Dialogue, which are romance-centric dialogue add-ons for all the marriage candidates in the game. Originally, I just had them as XNB mods, but I also added versions for the Content Patcher.

    I've had the great opportunity to have people translate my stuff into different languages, but my German translator recently reported a troubling bug: apparently my lines show up in English even when she's playing the German translation.

    I have two ideas for what might be happening...

    1) I was under the impression that you could have a content pack with multiple action commands in the config file, so I put all my translations (so far English, German, and Portuguese) into the single content pack, each with different actions to add my dialogue into the appropriate dialogue file. Was I wrong in that assumption, and is my English dialogue being added to the other files for some reason instead of what I intended? From what I know about programming that doesn't make much sense -- I checked and double-checked to make sure I didn't accidentally write the wrong file names or add in English lines among the other languages -- but I know weird things happen sometimes... The game wouldn't switch from reading the German dialogue file to the English one just for my lines, though, right? It doesn't make any sense.

    2) The multiplayer beta is messing with it somehow. Don't know how or why, but I figured it's a possibility with how unpredictable mods can be with beta games. I confirmed with my translator that she's playing the beta.

    I'm guessing the solution for either of these is to make separate content packs for each of the translations, but I wanted to run this by everyone to see if anyone had any other opinions/insights. If possible, it would be awesome if I could keep all the translations in a single pack, because that's super convenient for people to download, but of course a working mod takes precedence, haha.

    Thank you in advance for any help you can offer.
     
    • Pathoschild

      Pathoschild Tiy's Beard

      Content Patcher does support translations within one content pack. I'm guessing you put the language code in the Target field, which is incorrect (that field contains the asset name, not the filename). Instead you should use the Language condition to specify language-specific content. For example:

      Code:
      // default content for all languages
      {
         "Action": "EditData",
         "Target": "Characters/Dialogue/Abigail",
         "Entries": {
            "Sun_29": "Oh yeah? I guess that makes sense."
         }
      },
      
      // content for German only
      {
         "Action": "EditData",
         "Target": "Characters/Dialogue/Abigail",
         "When": {
            "Language": "de"
         },
         "Entries": {
            "Sun_29": "Oh ja? Das wundert mich nicht."
         }
      },
      
      (There's a list of language codes in the Content Patcher readme.)
       
      • glowy

        glowy Title Not Found

        I see! You were right in your guess. I've made the changes you suggested and will test it to see if it works as soon as I can. Thank you so much!
         

        Share This Page