Inherits: Object
Server that manages all translations.
Server that manages all translations. Translations can be set to it and removed from it.
void | add_translation ( Translation translation ) |
void | clear ( ) |
Array | get_loaded_locales ( ) const |
String | get_locale ( ) const |
String | get_locale_name ( String locale ) const |
void | remove_translation ( Translation translation ) |
void | set_locale ( String locale ) |
String | translate ( String message ) const |
Adds a Translation resource.
Clears the server from all translations.
Returns an Array of all loaded locales of the game.
Returns the current locale of the game.
Returns a locale's language and its variant (e.g. "en_US"
would return "English (United States)"
).
Removes the given translation from the server.
Sets the locale of the game.
Returns the current locale's translation for the given message (key).
© 2014–2020 Juan Linietsky, Ariel Manzur, Godot Engine contributors
Licensed under the MIT License.
https://docs.godotengine.org/en/3.2/classes/class_translationserver.html