API reference
API reference
Select your platform
No SDKs available
No versions available

ovr_LanguagePack_SetCurrent Function

Sets the current language to specified. The parameter is the BCP47 language tag. If a language pack is not downloaded yet, spawns automatically the ovr_AssetFile_DownloadByName() request, and sends periodic ovrMessage_Notification_AssetFile_DownloadUpdate to track the downloads. Once the language asset file is downloaded, call ovr_LanguagePack_GetCurrent() to retrieve the data, and use the language at runtime. ovrMessage_LanguagePack_SetCurrent will be generated in response.
First call ovr_Message_IsError() to check if an error occurred.
If no error occurred, the message will contain a payload of type ovrAssetFileDownloadResultHandle. Extract the payload from the message handle with ovr_Message_GetAssetFileDownloadResult().

Signature

ovrRequest ovr_LanguagePack_SetCurrent(const char *tag)

Parameters

tag: const char * The BCP47 language tag that identifies the language to be set as the current language.

Returns