Although I have only 3 years of experience translating games, I have over a dozen localizations under my belt, all above average works and some might even be, if I dare say, top notch quality works. Since the games industry has gave me so much throughout these years, I decided to write this article as an attempt to give something back. As a note, all of my examples are of localizations to the Brazilian Portuguese, my native language.
If there is one thing I started doing to help me improve my skils, it was to play games in their localized form. Back then, when I was still a small child, I had to play everything in English (or German, as was the case with my first Pokémon game) because localization wasn't a thing for a lot of the games. As such I learned a lot, from new vocabulary to interpretation by context. But nowadays, I like playing games in Portuguese (when available), including the ones I translate my self, so that I can see other people's solutions for some of the harder words, as well as how they got that result. With the industry's growth, it is also more common to see developers released their games localized, as a way to increase their reach.
Playing translated games, and translating them, also gave me some insight on the issues that arise when we try to adapt games to other languages. Since most of the articles I see here are either about the programing side of things, I will be focusing more on the developer <–> translator relationship. How about we start with the most common problem?
Imagine you were given the job to translate a comic book from language A to language B. But also you were not given any of the pages to work with, instead the company gave you a bunch of papers with sentences on it, and they have no numbers, so it's hard to tell their order. You might be able to translate everything, you might even be able to do a good job! But, because the text was out of context, you will almost always make mistakes. That's how it feels translating a game you do not have access to.
To give a more concret example, take Skulls of the Shogun localization to Portuguese. For the most part it is a very nice game, with some decent localization, untill you get to the single-word strings. You see, strings that are made up of single words (specially verbs) are the bane of translators. Each word can have multiple meanings, and some of them are in no way related to the other.
With Skulls of the Shogun, one could say that translating "Miss!" as "Faltar!" (meaning 'something, like a resource, is missing', instead of 'he missed an attack') in a strategy game is disingenuous by the translator, but at the same time, it doesn't hurt to have a comment by the developers saying exactly where this string shows up.
Another example is Endless Legend, a very slick turn-based strategy game. Although for the most part the strings are easy to work with, some of them can be quite tricky. For instance, five strings are literaly just a bunch of pronouns, without any semblance of context:
It took me some testing in the game to learn where each one of them were used, and how to best translate them. Like any other word, pronouns can be translated in a few different ways, so someone without access to the game could end creating a sentence that makes no sense.
So, whenever you see a string on your language file that contains a single word, try leaving a comment explaining it, as it will help ensuring a better end-result for your localizations, and therefore less headache trying to fix problems later on in the life of your game.
Look, everyone makes mistakes, no one is perfect. Sometimes it so happens that, for one reason or another, there will be missing strings on the language file. Although this is not that common, it can happen, and it can be hard for both the developer and translator to spot. For example, Endless Legend has been released for some time now, and has been localized officially to 6 different languages, yet no one bothered to tell Amplitude Studios that a string is missing! I personally have yet to finish my localization, but from testing it is possible to see that the "You" that appears in some places in-game can't be translated. Since it is such a small problem, and most localization companies don't bother checking things in-game, no one involved in the process noticed this issue.
While I was translating Hashi Link, for example, I played the game to see what it was all about, and to check some sentences I wasn't sure about its context. During my research, I noticed that two strings were missing from the file I received from the developers, which I then promptly contacted, and they quickly fixed the issue.
So a tip for this one is for developers to always check if the script you are using to create the localization file is grabbing all the strings. If need be, play the game with the file open on the side and manually check whenever possible, or replace all your strings by "Test" and play the game and see what remains unaltered. Even the smallest of issues can become a problem to your users.
ADAPT YOUR CODE
One of the main issues of the English language is its lack of gender association. While it allows for developers to easily create randomly generated sentences without too much of a problem, it is a headache for translators.
Let's take Crusader Kings II as an example, a game that is all about reciclying sentences. In this game, almost everything that can happen to a male character, can also happen to a female one too. A letter about an assassination atempt, someone insulting me for being of a different religion, or de jure declarations of war. These are things that can, and will, happen to the player, it doesn't matter his gender (actually, women are more prone to being attacked by other nations) and, to the English language, that's easy to code.
A simple example would be "Hi, my $PlayerPronoun, I'm here to tell you that..." and replace the variable with "Lord" or "Lady", depending on the player's gender. Doing that in Portuguese, for example, would create wrong sentences because of the "my", which needs to be translated as "meu" for "Lord", and "minha" for "Lady". And since the variables "Lady" and "Lord" are used in multiple situations, I can't "hack" my way by translating "Lady" as "minha senhora" and remove the "my" from the main string.
This is probably one of the hardest issues to fix in games with proceduraly generated content, which also makes them one of the hardest to localize. The only tip I can give on this one is that each language has its own set of rules for genders, with some overlapping, so try to research a bit first, ask people around, and add more strings so they can fit to more situations (instead of using "Lady" everywhere, create several "Lady" strings to be used in different contexts, allowing the translator to change things as he needs).
EXPLAIN YOUR CODE
Another thing about the relation between code and language are the variables. In the previous example from Crusader Kings II, you can see they use variables in the middle of the string. That's very common in games, but if your going to do it, try to leave an explanation for your translators.
Each game uses different kinds of ways to communicate with the code. Not only that, but sometimes a string will have a variable that is calling another string, and sometimes it will have a variable that is simply calling a nuimber, or the player name, or some other in-game value. Make it clear what your variables are calling. For example, look at the following string from Endless Legend:
$Number $Title $Caption
To fully understand it, you'd either need to know what $Caption and $Title are referring to, or play the game and see what it shows. Not only does this string lacks explanation, but it also calls strings that are in a second, different, file, making it even harder on the translator to guess what any of this means.
In the end, I think that developers that want to see their games properly localized need to think as translators not as a means to an end, but someone that is integral to their team as the designer, or the programmer. Having a game that is poorly localized (missing strings, things out of context, nonsensical sentences generated by the game, etc.) is worse than not have a localization at all, so think ahead. Users playing the localized version will either think the developers were too lazy to add a proper localization, or that their language is not important enough, that they are not important enough.
So, when you contract a company or someone to translate your game, explain them everything. Explain what kind of game you have (is it humoristic, is it serious, what is its genre, does it uses a lot of prceduraly generated content), tell them about the variables in your strings, ask if there is anything that needs changing and, whenever possible, give a playable copy of your game. Most of these issues can be fixed by having the translator play and understand your game, and others by maintaining an open channel of communication with the translation team.