What is the Best Practice for Localization / String Management?

Hi everyone,

I’m working on a project and trying to set up a good system for localization and managing all my game’s UI text. My goal is to avoid hard-coding text in my events so that it’s easy to manage and, in the future, easy to hand off to a translator.

I’ve spent a lot of time trying a few different methods based on tutorials and examples, but I’ve run into a roadblock with each one and I’m getting a bit lost. I’m hoping the community can point me toward the current “best practice” for this.

Here is what I have tried so far:

Method 1: The Yarn/Ink Dialogue Tree Extension

  • Setup: I created a strings.yarn.txt file with simple key: value pairs (e.g., crafting_title: UPGRADE STATION).

  • Action: At the beginning of my scene, I use the Load dialogue tree from a JSON file action to load the file.

  • Expressions Tried: I’ve tried to get the text using DialogueTree::VariableString(“key”), InkDialogTree::StoryVariableText(“key”), and other variations.

  • Result: No matter which expression I use, the text objects on my screen remain empty. I have confirmed that the “Load” action is running before I try to get the text.

Method 2: Loading a CSV File

  • Setup: I created a localization.csv file with columns for key and en.

  • Action: I used the Load a scene variable from a JSON file action to load the .csv file into a scene structure variable called AllText.

  • Expression Tried: I tried to access the data using AllText[0].en.

  • Result: This also resulted in empty text objects, so it seems this action doesn’t parse CSVs as I expected, or I am doing it wrong.

My Question:

So I feel a bit stuck. For a medium-to-large project in the current version of GDevelop, what is the community’s recommended way to handle this?

  • Am I missing a simple step in the Yarn or CSV methods that’s causing them to fail?

  • Is the Global Variable Structure method really the most stable way, even if it gets very large?

  • I also just thought of making something like if Global Variable is EN change text to “english” and like that for each language but it also seems like a lot of work.

  • Is there another extension or a built-in feature I’m overlooking?

Any advice or a link to a working example would be hugely appreciated. I’m feeling a bit stressed and turned around on this, and I want to make sure I’m building on a good foundation.

Thanks in advance!

Don’t take my words as way to go but just as my personal experience
Cause i see you did try some stuff yet i am not sure where you made mistake

ONLY logic i seen for multilanguage in gdevelop made by user was when he went with array or structure vars
But that was not like in game dialogues but more of a all UI text translated to different languages
And simply shifting child vars to change language

If you would have heavy text based game or at least more than few dialogues i would like you look into loading them from external files

I seen ppl use Yarn for dialogues so i guess you could have json files in your project and just load proper ones when needed IF you would not want to go with array/structures

But the fact nothing is loading for you indicates you simply did something wrong
You should either look for how to load text from json or how to use yarn tutorials/guides and then try to load at least 1 line of text
And move from that point on

it is an RPG so i imagine alot of text will be coming. but yeah i definetly did not do something right. and i got flustered taking a breather and will come back to it. I will read on Json Importing.