0 votes

Since recent betas, Godot forces the game to use the player's locale. In some games this is not wanted so it should be possible to change that behaviour manually but it seems that it is not possible?

Project settings seems to not contain option for that.

Calling TranslationServer.set_locale("en-US") does nothing, no matter what parameter is used.

Setting all controls's LocalizeNumeralSystem to false in a loop will crash the game because of current bug(s) in Godot.

Setting the LocalizeNumeralSystem manually from the editor does nothing.

I managed to find a workaround that may or may not work in all situations. When using C#, it's possible to override locale this way:

CultureInfo ci = new CultureInfo("en-US");
Thread.CurrentThread.CurrentCulture = ci;
Thread.CurrentThread.CurrentUICulture = ci;

But this works only in Mono projects and probably only when inserting values from the code.

So how to set locale so that when a developer for example puts a value 123.45 to a label the value is 123.45 and not something else (like 123,45)?

Godot version 4.0 Beta 16
in Engine by (95 points)

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.