Skip to content

Commit

Permalink
Merge pull request #1 from b03605079/patch-1
Browse files Browse the repository at this point in the history
Update functions.cpp
  • Loading branch information
teschnei committed Apr 19, 2015
2 parents 8e21c4e + 5afe605 commit af6d266
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion xiloader/functions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -77,11 +77,12 @@ namespace xiloader
unsigned int functions::GetRegistryLanguage(int lang)
{
const char szLanguageTags[4][255] = { { "" }, { "US" }, { "EU" }, { "EU" } };
const char szLanguageTags2[4][255] = { { "" }, { "Enix" }, { "Enix" }, { "Enix" } };
char szRegistryPath[MAX_PATH] = { 0 };

HKEY hKey = NULL;

sprintf_s(szRegistryPath, MAX_PATH, "SOFTWARE\\PlayOnline%s\\SquareEnix\\PlayOnlineViewer\\Settings", szLanguageTags[lang]);
sprintf_s(szRegistryPath, MAX_PATH, "SOFTWARE\\PlayOnline%s\\Square%s\\PlayOnlineViewer\\Settings", szLanguageTags[lang], szLanguageTags2[lang]);
if (!(::RegOpenKeyExA(HKEY_LOCAL_MACHINE, szRegistryPath, 0, KEY_QUERY_VALUE | KEY_WOW64_32KEY, &hKey) == ERROR_SUCCESS))
return 1;

Expand Down

0 comments on commit af6d266

Please sign in to comment.