kwsch / NHSE

Animal Crossing: New Horizons save editor
https://berichan.github.io/GetNHSE/
GNU General Public License v3.0
1.03k stars 260 forks source link

Language problem #140

Closed littlecxm closed 4 years ago

littlecxm commented 4 years ago

Is your feature request related to a problem? Please describe.

Describe the solution you'd like

kwsch commented 4 years ago

DevUtil is mostly for me to just run periodically to backfill the program translation resources.

Here's the process I use to get the resources updated:

  1. Open the program
  2. Open a save file
  3. Ensure the current language is English. If the language is not english, close the program entirely and start from 1.
    • Opening the editor is important, as the translation updating requires the base translation context to be initialized (and it's only initialized whenever something is translated; Main is not translated).
    • The base translation context should always be English, as that's what all the default values in the program GUI are.
  4. Close the save file Editor window
  5. Press the hotkey from the main window
  6. Assets get updated; program closes when finished.
  7. Push commit with updated strings
kwsch commented 4 years ago

Apologies if it's a little hard to follow; I had originally developed the translation strategy for PKHeX, and copied it over to NHSE. The logic is pretty rigid, since it never needed to be flexible.

A summary of how it updates the translations:

I definitely could rework the translation logic so that it worked regardless of current language, but I don't think it's worth investing the the effort (better spent elsewhere) since it works with the steps above.

littlecxm commented 4 years ago

got it👍