Threshold-Yuzu/Install.cmd

41 lines
1.5 KiB
Batchfile
Raw Normal View History

2021-10-05 19:08:29 +00:00
@echo off
2021-10-05 13:11:48 +00:00
FOR /F "tokens=2* skip=2" %%a in ('reg query "HKCU\Software\Valve\Steam" /v "SteamPath"') do set SteamPath=%%b
REM If return value is not an exist path(Err Msg)
if not exist "%SteamPath%" (
2021-10-05 19:08:29 +00:00
echo No steam detected. Please run steam at least once.
2021-10-05 13:11:48 +00:00
pause
exit
)
for %%I in (.) do set CurDirName=%%~nxI
if exist "%SteamPath%\skins\%CurDirName%" (
2021-10-05 19:08:29 +00:00
goto Override
) else (
goto Apply
)
exit
:Override
set /P Override=Skin already existed, Override?[y/N]
if "%Override%"=="y" goto Apply
if "%Override%"=="Y" goto Apply
exit
:Apply
del /f /q "%SteamPath%\skins\%CurDirName%"
2021-10-05 19:08:29 +00:00
mkdir "%SteamPath%\skins"
2022-04-16 10:28:24 +00:00
xcopy /e /y /i "..\%CurDirName%" "%SteamPath%\skins\%CurDirName%"
2021-10-05 19:08:29 +00:00
reg add HKCU\Software\Valve\Steam /v SkinV5 /t REG_SZ /d %CurDirName% /f
2023-03-17 15:12:39 +00:00
echo Set oWS = WScript.CreateObject("WScript.Shell") > CreateSteamLauncherShortcut.vbs
echo sLinkFile = "%HOMEDRIVE%%HOMEPATH%\Desktop\Steam.lnk" >> CreateSteamLauncherShortcut.vbs
echo Set oLink = oWS.CreateShortcut(sLinkFile) >> CreateSteamLauncherShortcut.vbs
echo oLink.TargetPath = "%SteamPath%\skins\%CurDirName%\SteamLauncher.exe" >> CreateSteamLauncherShortcut.vbs
echo oLink.IconLocation = "%SteamPath%\steam.exe, 1" >> CreateSteamLauncherShortcut.vbs
echo oLink.Save >> CreateSteamLauncherShortcut.vbs
cscript CreateSteamLauncherShortcut.vbs
del CreateSteamLauncherShortcut.vbs
cls
echo Shortcut Created. Please use the shortcut on desktop to open Steam.
2021-10-05 19:08:29 +00:00
echo Enjoy your new steam! :^)
cd /d "%SteamPath%\skins\%CurDirName%"
2022-04-16 10:28:24 +00:00
start explorer.exe .
pause