protected string GetSoftwareRegistryValue(string subpath, string folderKeyName)
{
return (string.IsNullOrEmpty(subpath) ? null :
GetRegistrySoftwareValue(Registry.LocalMachine, subpath, folderKeyName)
?? GetRegistrySoftwareValue(Registry.CurrentUser, subpath, folderKeyName))
?? (SteamApplicationId.HasValue ?
GetRegistrySoftwareValue(Registry.LocalMachine, SteamBase + SteamApplicationId.Value, SteamFolderKeyName) : null);
}