2
0
mirror of https://github.com/ValveSoftware/Proton synced 2025-08-22 10:17:18 +00:00

steam_helper: Add SteamPath and ValvePlatformMutex env vars.

CW-Bug-Id: #25738
This commit is contained in:
Paul Gofman 2025-07-30 10:57:00 -06:00
parent d008ef6f10
commit 6c17f3e1a1

View File

@ -801,6 +801,8 @@ int main(int argc, char *argv[])
if (getenv("SteamGameId"))
{
WCHAR path[MAX_PATH], *p;
/* do setup only for game process */
event = CreateEventW( NULL, FALSE, FALSE, L"Steam3Master_SharedMemLock" );
@ -811,6 +813,17 @@ int main(int argc, char *argv[])
set_active_process_pid();
SetEnvironmentVariableW(L"SteamPath", L"C:\\Program Files (x86)\\Steam");
*path = 0;
GetModuleFileNameW(NULL, path, ARRAY_SIZE(path));
p = path;
while (*p)
{
if (*p == '\\') *p = '/';
++p;
}
SetEnvironmentVariableW(L"ValvePlatformMutex", path);
setup_steam_registry();
setup_steam_files();