From 6ee67d962b1eb4cb979d115f632f612cc0b0a06f Mon Sep 17 00:00:00 2001 From: Bryson <13501615+brysondev@users.noreply.github.com> Date: Mon, 4 Jan 2021 20:44:20 -0500 Subject: [PATCH] v1.2.1 Fixed issue with 32 bit systems not indexing correctly --- of_install.bat | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/of_install.bat b/of_install.bat index 2fd93b9..be8afa2 100644 --- a/of_install.bat +++ b/of_install.bat @@ -56,17 +56,20 @@ if not exist %STEAM_REG_PATH%\NUL ( ) :32bitSteam -set PATH_STEAM=HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Valve\Steam +:: Steam fucked up the registry keys for 32 bit systems https://i.imgur.com/w816RTW.png +:: Gotta use HKLM + +set PATH_STEAM=HKEY_LOCAL_MACHINE\SOFTWARE\Valve\Steam set VALUE_STEAM=InstallPath -FOR /F "usebackq skip=2 tokens=1,2*" %%A IN (`REG QUERY %PATH_STEAM% /v %VALUE_STEAM% 2^>nul`) DO ( +FOR /F "usebackq skip=2 tokens=1,2*" %%A IN (`REG QUERY %PATH_STEAM% /reg:32 /v %VALUE_STEAM% 2^>nul`) DO ( set STEAM_REG_PATH=%%C ) set "STEAM_REG_PATH=%STEAM_REG_PATH%\steamapps\sourcemods" - -if not exist %STEAM_REG_PATH%\NUL ( - echo Steam not installed! ^(Or you've messed with your registry...^) +echo %STEAM_REG_PATH% +if not exist "%STEAM_REG_PATH%\" ( + echo Steam not installed! ^(Or something broke...^) goto exitmain ) @@ -100,4 +103,4 @@ echo. goto exitmain ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: :exitmain -PAUSE +PAUSE \ No newline at end of file