?
int SteamDecode() {
TCHAR cData[255];
DWORD StringSize = 255;
HKEY hKey = NULL;
if(RegOpenKeyEx(
HKEY_CURRENT_USER,
"Software\\Valve\\Steam",
NULL,
KEY_QUERY_VALUE,
&hKey) == ERROR_SUCCESS)
{
cout<<"No steam installed on this computer!"<<endl;
getch();
return -1;
}
if(RegQueryValueEx(hKey,
"SteamExe",
NULL,
NULL,
(LPBYTE)cData,
&StringSize) == ERROR_SUCCESS)
{
cout<<"Steam Value SteamExe does not exist.";
getch();
return -1;
}
RegCloseKey(hKey);
if (strchr(strchr(cData,'/'),'/') != NULL) *strrchr(cData,'/') = '\0';
cout<<cData<<endl; // Steamfolder, now you can do whatever you want
return 0;
}
da isn beispiel list steam regkey aus