:: CONFIGURATION
:: time(in minutes)
set time=60
:: program name
set program=runserver.bat
:: run command(the batch command)
set batchCommand=runserver.bat D:\Sexyscape server\bin\runserver.bat
:: this file name(the name)
set this=auto.bat
:: DO NOT EDIT BELOW ONLY IF YOU KNOW WHAT ARE YOU DOING!
:: DO NOT EDIT BELOW ONLY IF YOU KNOW WHAT ARE YOU DOING!
:: DO NOT EDIT BELOW ONLY IF YOU KNOW WHAT ARE YOU DOING!
:: init
@echo off
cls
title Simple auto-restarter by D4NyZ
echo Opening the application
start %batchCommand%
echo Application opened
ping 127.0.0.1 -n %time% > nul
echo Closing the application
taskkill /im %program%
echo ...
:: executes this batch file again
%this%