Skip to content
This repository was archived by the owner on Mar 31, 2023. It is now read-only.

Commit 0ab7c94

Browse files
author
brysondev
committed
v2.1.0 - Cleanup after itself and works on windows 7
1 parent 19e01d1 commit 0ab7c94

1 file changed

Lines changed: 34 additions & 7 deletions

File tree

of_install.bat

100644100755
Lines changed: 34 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ goto murse
4444
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
4545
:murse
4646
setlocal ENABLEEXTENSIONS
47-
set MURSE_PATH="%TEMP%\murse\"
47+
set MURSE_PATH=%TEMP%\murse\
4848
set PATH_STEAM=HKEY_CURRENT_USER\SOFTWARE\Valve\Steam
4949
set VALUE_STEAM=SourceModInstallPath
5050
set STEAM_EXE=SteamExe
@@ -60,15 +60,18 @@ if not exist %STEAM_REG_PATH%\NUL > nul 2>&1(
6060
)
6161
)
6262

63-
if not exist "%MURSE_PATH%\murse.exe" (
63+
if not exist "%MURSE_PATH%murse.exe" (
6464
echo Installing Murse CLI...
6565
echo.
6666
cd %TEMP%
6767
md "murse"
6868
cd "murse"
69-
powershell -Command "Invoke-WebRequest https://dl.spiderden.net/murse/windows -Outfile murse.exe"
69+
powershell -Command "(New-Object Net.WebClient).DownloadFile('https://git.sr.ht/~welt/murse/refs/download/v0.3.0/murse-v0.3.0-windows-386.zip', 'murse.zip')"
70+
Call :UnZipFile "%MURSE_PATH%" "%MURSE_PATH%murse.zip"
7071
)
71-
72+
goto verify
73+
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
74+
:verify
7275
echo Verifying Murse exists...
7376
cd /D "%MURSE_PATH%"
7477
murse.exe -h
@@ -83,22 +86,38 @@ echo Murse verified!
8386
:: cd /D %STEAM_REG_PATH%
8487
goto installOF
8588

89+
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
90+
:UnZipFile <ExtractTo> <newzipfile>
91+
set vbs="%temp%\_.vbs"
92+
if exist %vbs% del /f /q %vbs%
93+
>>%vbs% echo Set fso = CreateObject("Scripting.FileSystemObject")
94+
>>%vbs% echo If NOT fso.FolderExists(%1) Then
95+
>>%vbs% echo fso.CreateFolder(%1)
96+
>>%vbs% echo End If
97+
>>%vbs% echo set objShell = CreateObject("Shell.Application")
98+
>>%vbs% echo set FilesInZip=objShell.NameSpace(%2).items
99+
>>%vbs% echo objShell.NameSpace(%1).CopyHere(FilesInZip)
100+
>>%vbs% echo Set fso = Nothing
101+
>>%vbs% echo Set objShell = Nothing
102+
cscript //nologo %vbs%
103+
if exist %vbs% del /f /q %vbs%
104+
goto verify
86105
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
87106
:installOF
88107
echo.
89108
echo Installing Open Fortress...
90109
echo.
91110

92111
:: TODO: Possibly let them input threads, but honestly this should be fine for now...
93-
murse.exe upgrade "%STEAM_REG_PATH%\open_fortress"
112+
murse.exe upgrade "%STEAM_REG_PATH%\open_fortress" -u "https://toast3.openfortress.fun/toast"
94113
if %ERRORLEVEL% EQU 1 (
95114
echo Something went wrong...
96115
goto exitmain
97116
)
98117
echo Validating just in case...
99118
echo This will take a while...
100119
echo.
101-
murse.exe verify "%STEAM_REG_PATH%\open_fortress" -r
120+
murse.exe verify "%STEAM_REG_PATH%\open_fortress" -r -u "https://toast3.openfortress.fun/toast"
102121
if %ERRORLEVEL% EQU 1 (
103122
echo Something went wrong...
104123
goto exitmain
@@ -166,11 +185,19 @@ echo MMMMMMMMMMMMMMMMWKkl;''''''''''''''''''''''''''''''''';lkKWMMMMMMMMMMMMMMMM
166185
echo MMMMMMMMMMMMMMMMMMWWKkdc;''''.''''''....''''..'''';cokKWWMMMMMMMMMMMMMMMMMM
167186
echo MMMMMMMMMMMMMMMMMMMMMMWNKOxol:;,,'''''''''',;:loxOKNWMMMMMMMMMMMMMMMMMMMMMM
168187
echo MMMMMMMMMMMMMMMMMMMMMMMMMMMWWNXK00OOOkOOO00KXNWWMMMMMMMMMMMMMMMMMMMMMMMMMMM
188+
echo.
189+
echo Cleaning up...
190+
if exist %MURSE_PATH% (
191+
cd %TEMP%
192+
@RD /S /Q %TEMP%\murse
193+
)
169194
goto exitmain
195+
170196
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
171197
:exitmain
172198
echo.
173199
echo For any issues you are unsure about regarding the install, kindly ping bryson on the offical public Open Fortress Discord in #windows-troubleshooting.
174200
echo Discord: https://discord.gg/mKjW2ACCrm
175201
echo.
176-
PAUSE
202+
PAUSE
203+
EXIT

0 commit comments

Comments
 (0)