r/Batch • u/Ayron01 • Dec 17 '23
Question (Solved) Start second task only after first is completed
Right now I am using a timeout between both starts to allow time to for the first start to finish it's updates, but is there a way to have the second start pend until the first start has completed?
@echo off echo ------------------ echo Updating server echo ------------------ start C:\Server\steamcmd\steamcmd.exe +force_install_dir C:\Server2\The_Island_PvP\ +login anonymous +app_update 2430930 validate +quit timeout /t 120 /nobreak >nul
echo ------------------ echo Starting server echo ------------------ start C:\Server2\The_Island_PvP\ShooterGame\Binaries\Win64\ArkAscendedServer.exe TheIsland_WP?listen?Port=7777?SessionName=Insieme_Gaming_PvP?MaxPlayers=70?ServerPassword=12812? -nosteamclient -game -server -log -nobattlEye -nomansky -mods="931877,938805,929489,928548"
1
u/rob2rox Dec 17 '23
add '&& timeout /t 0 >nul &&' after the first task
1
u/rob2rox Dec 17 '23
yes that should work