MonoGame has some pretty robust built-in features for handling localization and fonts. There is an example that walks you through supporting different languages (cultures) and even optimizing your different fonts so that they only contain the characters that your game actually uses:
I’m wondering if it’s possible to leverage all of this built-in functionality while allowing the user to change languages (culture) at runtime? All of the examples I’m seeing seem to imply that this can only be set in the Game class’ constructor and cannot be changed while the game is being played (say from an Options menu for instance…). Any insight is appreciated!
I didn’t look thru the code for that but another game i used to mod a bit did it in a very simple way.
Basically it kept a string table in the language the game was designed in.
It kept folders for copys of it in other languages.
It could if it were in monogame it could very well keep a separate spritefont in that folder for that language.
Change the language load the new font and associated string table at runtime.
I don’t think there are many os’s out there were loading a txt file is a big deal.
So you could even add it to your project and set it to copy always with little hastle and file io it in.
Or you could do all the content processor stuff i suppose instead.