batch file help

  • Offline dekela
  • First Blood
  • ***
  • Posts: 79

batch file help

« posted: Jul 02, 2016, 07:18 AM »
i am currently running the following bat file to start my dedi server and servermonitor.bat.
Code: [Select]
@echo off

taskkill /f /fi "status eq not responding" /im arma3server.exe
taskkill /f /im arma3server.exe
timeout 1

taskkill /f /fi "status eq not responding" /im arma3.exe
taskkill /f /im arma3.exe
timeout 1

taskkill /im Bec.exe
taskkill /f /im cmd.exe /fi "windowtitle eq servermonitor.bat"
timeout 2
echo Kill all instances for safety

timeout 6
::CHANGE THE DIRECTORY BELOW TO THE PROPER LOCATION
set becpath="C:\Games\ArmA3\A3Master\A3DS\profiles\BattlEye\"
cd /d %becpath%
start "" /min "Bec.exe" -f Config.cfg
timeout 1
echo Battleye has started..
timeout 1
echo Starting ARMA 3 Stratis Server...
::CHANGE THE DIRECTORY BELOW TO THE PROPER LOCATION
cd "C:\Games\ArmA3\A3Master\"
start "" /HIGH /affinity 11 /min /wait "C:\Games\ArmA3\A3Master\arma3server.exe" -noPause -noSound -cpuCount=4 -maxMem=2048 -exThreads=7 -cfg=A3DS\basic.cfg -config=A3DS\server.cfg -profiles=A3DS\Profiles -servermod= -mod=@infiSTAR_A3;@asm; -filePatching -noLogs -world=empty -autoinit -loadMissionToMemory
echo Server started succesfully
timeout 5
echo ARMA 3 Stratis Server has started
::CHANGE THE DIRECTORY BELOW TO THE PROPER LOCATION
set ServerMonitorPath="C:\Games\ArmA3\A3Master\A3DS\profiles\"
cd /d %ServerMonitorPath%
start "" "servermonitor.bat"
echo Server Monitor has started. Have Fun
timeout 3
exit
my question is, can i use this same bat to start multiple servers, and if so, how?
thanks

Re: batch file help

« Reply #1 posted: Jul 03, 2016, 04:23 AM »
just rename arma3server.exe to another thing. then you will use differents executable to each server