spacer graphic
spacer graphic
Montage of games AGS Logo
spacer graphic

 

spacer graphic
Menu
spacer graphic Home
About
News
Features
Download AGS
spacer graphic Games 
Games main page
Award Winners
Picks of the month
Short games
Medium length games
Full length games
In Production
Hints & Tips
Community
Forums
AGSers World Map
Member websites
Chat
Resources
Tutorials
FAQ
Knowledge Base
Downloads
Links
AGS-related links
* AGS Manual
  * Scripting
    * Game / Global functions

ChangeTranslation

static bool Game.ChangeTranslation(string newTranslationName)
Changes the active translation to newTranslationName. This must be the file name without the extension, for example "French" or "Spanish". It can also be a blank string, in which case the current translation will be switched off and the game will revert to the default language.

Returns true if the translation was changed successfully, or false if there was a problem (for example, you specified an invalid translation).

NOTE: This is a static function, and thus need to be called with Game. in front of it. See the example below.

Example:

if (Game.ChangeTranslation("Spanish") == true)
{
  Display("Changed the translation to Spanish!");
}
else
{
  Display("Unable to change the translation");
}
will attempt to change the translation to Spanish

Compatibility: Supported by AGS 3.1.0 and later versions.

See Also: Game.TranslationFilename, IsTranslationAvailable


User comments and notes
There are currently no user comments on this page.
The user comment facility is currently disabled.