Recently I have been trying to debug why my images would not translate into other people’s languages. I am using a custom system that uses RobloxLocaleId to lookup the correct image IDs to use for a player.
However, I was today made aware that this system doesn’t work for unsupported languages - that using RobloxLocaleId doesn’t work properly and so for unsupported languages, there is no one single way to accurately identify the players locale.
This is the output I obtained from a Dutch user with their language set to Nederlands on the site:
RobloxLocaleId: en-us
SystemLocaleId: nl-nl
Translator.LocaleId: nl-nl
This player then changed their language to English and got the following:
RobloxLocaleId: en-us
SystemLocaleId: nl-nl
Translator.LocaleId: nl-nl
Yep… thats exactly the same, even though the language on the website was changed and they could see the correct Cloud Table (AutoLocalize) translations. Note that here, Translator.LocaleId is returning the wrong value even though nl-nl is this users location. Their language is not set to this locale at all!
Essentially there is no way that my game can determine what language a player has set on the website. This means that image translations will always localise to English for unsupported languages, i.e languages that show this when you switch:
I manually changed my website language to Spanish, a supported language, and behold…
RobloxLocaleId: es-es
SystemLocaleId: en-gb
Translator.LocaleId: es-es
It works!
However, what makes this very frustrating is that RobloxLocaleId is changed when you use the Studio emulator to change your Locale, meaning that for months I have believed my manual translationshave been displaying perfectly, when in fact they haven’t.
I am unsure what the underlying problem here really is - whether the Studio emulator’s behaviour is wrong, or whether RobloxLocaleId in game is wrong. One thing is for sure though - the behaviour of RobloxLocaleId is inconsistent at best, broken at worst.