Getting automatic Roblox translation

  1. What do you want to achieve?
    I want to get the automatic Roblox translations of strings in my game in a script. OR somehow translate a string using some sort of function.
  2. What is the issue?
> local LocalizationService = game:GetService("LocalizationService")
> 
> local res, translator = pcall(function()
> 
>      return LocalizationService:GetTranslatorForLocaleAsync("es")
> 
> end)
> 
> if res then
> 
>      local sourceTranslation = translator:Translate(game, "Animals")
> 
>      print(sourceTranslation)
> 
> end

Trying to get this to return the translation of “Animals” in Spanish but it’s just returning “Animals”.

Automatic translation done by Roblox ^

  1. What solutions have you tried so far?
    Looked around the dev forum, watched videos on localization. Can’t get this to work the way I want it to. Hope I can get some pointers in the right direction :slight_smile:
1 Like


That translation should be correct

edit: or is the function not returning what was in your screenshot?

Yes the translation is correct however (apologies if I wasn’t being clear), I can’t get the script to return the Spanish translation which is what I am trying to achieve.

Tested it myself and am experiencing the same issue. I’ll test a few things and see if I can resolve the issue

OK, I think the code only reads from the localization table that you already created.


So you would have to create it initially in the localization area first (based on what I have been able to find)

Thanks for taking the time but, the translation is already created by Roblox automatically. The goal is to fetch the automatic translation, not to create my own.