Anyone that can help me with an auto update script/bat for my server?
Iv got this in my START.bat, maybe in this startup code so it does only update / not validate so i dont loose my edited files(eventx.xml etc.)
@echo off
TITLE DayZ SA Server - Status
COLOR 0A
:: Variables::
::DayZServer_64.exe path
set DAYZ-SA_SERVER_LOCATION="C:\dayzserver"
::Bec.exe path
set BEC_LOCATION="C:\dayzserver\battleye\Bec"
::::::::::::::
echo Agusanz
goto checksv
pause
:checksv
tasklist /FI "IMAGENAME eq DayZServer_x64.exe" 2>NUL | find /I /N "DayZServer_x64.exe">NUL
if "%ERRORLEVEL%"=="0" goto checkbec
cls
echo Server is not running, taking care of it..
goto killsv
:checkbec
tasklist /FI "IMAGENAME eq Bec.exe" 2>NUL | find /I /N "Bec.exe">NUL
if "%ERRORLEVEL%"=="0" goto loopsv
cls
echo Bec is not running, taking care of it..
goto startbec
:loopsv
FOR /L %%s IN (30,-1,0) DO (
cls
echo Server is running. Checking again in %%s seconds..
timeout 1 >nul
)
goto checksv
:killsv
taskkill /f /im Bec.exe
taskkill /f /im DayZServer_x64.exe
goto startsv
:startsv
cls
echo Starting DayZ SA Server.
timeout 1 >nul
cls
echo Starting DayZ SA Server..
timeout 1 >nul
cls
echo Starting DayZ SA Server...
cd "%DAYZ-SA_SERVER_LOCATION%"
start DayZServer_x64.exe -config=serverDZ.cfg -port=2302 -dologs -adminlog -noFilePatching -BEpath=C:\dayZServer\battleye -profiles=C:\dayzserver\playerLogs
FOR /L %%s IN (45,-1,0) DO (
cls
echo Initializing server, wait %%s seconds to initialize Bec..
timeout 1 >nul
)
goto startbec
:startbec
cls
echo Starting Bec.
timeout 1 >nul
cls
echo Starting Bec..
timeout 1 >nul
cls
echo Starting Bec...
timeout 1 >nul
cd "%BEC_LOCATION%"
start Bec.exe -f Config.cfg
goto checksv
Thanks for the help