Tuesday, August 18, 2015

Localization in Catch a Falling Star - Multiple language support

When we started with the idea of Catch a Falling Star, we saw an opportunity to add some localization to it - that is, to have the game be in more than one language. The game doesn't have a story line, so the text is really not a lot. "Play" here and "High Score" there, etc.

We bought an asset on Unity's Asset store that helped a great deal, it's called G2U (which stands for Google 2 U), check it out here: https://www.assetstore.unity3d.com/en/#!/content/11818 - if you plan on adding multiple language support to your game, I'd highly recommend it.

The nice part about G2U is that it connects to a Google Docs Spreadsheet, so it's really easy to have several people be able to edit it. This spreadsheet basically contains the different versions of text for each language you plan on supporting.

To start with, we'll have language support for Catch a Falling Star for English, Afrikaans (because we're Afrikaans hehe), French and German. Now, we are using Google Translate, so hopefully the fact that the stuff we're translating is simple words or phrases makes it accurate enough.

In our Spreadsheet we have the first column basically being the unique identifier, with each column having the English, Afrikaans, French and German versions. The nice thing, adding a new language would be as simple as adding another column and filling it in.

Now, in Catch a Falling Star, a lot of the elements are actually images and not text. This makes localization a bit more work, since each image containing text I basically have to make several versions for. Luckily, we don't have too much text in the game, so it only took an hour or two.

Next enters Jayson - damn what a great coder he is. He created a very easy to use, but very powerful script to implement this in our game. The script is all of 115 lines of code (so far). And boy does it make implementing it so easy! We created a localization manager, and plopped the script onto that. All you need to do then is simply populate the array with all of your objects that has different language versions. That's really pretty much all it takes to get it to work. And does it work well!

Check out the 4 different login screens:





It works great!

(by the way, if you're French or German, and you see a mistake, please be so kind and point that out in the comments below - would really appreciate that!)

A simple thing like adding multiple language support to your game can make a massive difference. Not everyone can speak English after all, and I think our players will really appreciate the extra effort we're putting in :)

No comments:

Post a Comment