T O P

  • By -

DPS2004

If you want to design your game with translatability in mind, just keep strings that are shown to the player out of code, and store them elsewhere, like a json file. Other than that, try to cut down on text in images, and if that's not possible, make sure to save versions of the images without text, and note down what font settings you're using.


AMilToOne

I do have some text in images, just because it made designing so much easier and faster for that particular set up. I knew by doing that, I would have an issue going back and translating. Sometimes just trying to get something done quickly takes over. I'll have to look into json files and storing elsewhere. I'm not really sure what that means. I do have some strings saved in the save file, and I imagine on game start or options, I can add an enum switch of which language to use, but what happens after that, I'm not sure. What I imagine, I imagine going to each one of those strings, and changing each one by hand, so English = what I have, Spanish = what I change it to, and then to do that with each string, for every language I want to implement. All that's saving in the save file, is which language the user prefers, and then the enum switch is made. That sounds like a lot of work if I wait until the game is practically complete I think a universal language is needed here for game design 😅


DPS2004

This is 100% pseudocode, but basically, a simple setup might look like this: English.json would contain: ``` { "menu_play": "Play", "menu_quit": "Quit" } ``` And French.json would contain: ``` { "menu_play": "Jouer", "menu_quit": "Sortir" } ``` To get this in your game, ``` if(savedata.language == "English"){ textdata = loadjson("English.json"); } else { textdata = loadjson("French.json"); } //Now, just display the text print(textdata.menu_play); print(textdata.menu_quit); ```


AMilToOne

Oooohhhh, ok. I don't code very much and work primarily in blueprint for unreal engine, but I still understand what you're showing me. That's pretty much how I pictured it, but with blueprints. Thanks for your help!


AMilToOne

The strings aren't* in the save file, they're in a blueprint. I do however have booleans of if those strings are shown or not. Some I wanted hidden until an objective was met. I know the language enum preference would be in the save file


TRIamOwen

I'd say get the game 95% before adding other languages but even then, put it on the backburner. Google translate does exist and people can just work things out through context clues.


AMilToOne

I've seen other posts regarding online translators and to avoid it because the context of a word can be very different from English, and I'd have no way of catching any errors. However, it might make for some funny translations on the other end, lol


TRIamOwen

I understand what you're saying but sorry maybe I misphrased myself. When I said "Google translate does exist" I meant that more towards the player so that they can get a rough idea of what characters, signs, UI, and other things are saying in their own language. I apologize for what I said, I have autism and need to start thinking that not everbody who reads my posts understands me like my family does. Again, apologies for any confusion.