Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to create a batch file for a friend because he has some problems on minecraft. He needs to launch minecraft 80 times without closing java error... I have 2 batches, one with a while, and an other one executing java command for launching minecraft.

title Script Minecraft
set tour=10
set tour2=tour

set /a tour=tour-1
call "D:\thepath\Minecraft2.bat"
if %tour%==0 goto suite
goto boucle

wait javaw.exe

set /a tour2=tour2-1
taskkill /F /IM "javaw.exe"
if %tour2%==0 goto fin
goto boucle2

echo Appuyez sur une touche pour quitter...
pause >nul

and the other one

@echo off
java -Xmx2048m -Xms1024m -cp "D:\thepath\Minecraft.exe" net.minecraft.LauncherFrame

My problem is that when it calls the second batch, it's waiting for closure of the window but we must leave them opened !

If someone has already encountered this problem, I'd be grateful.


PS: If my english is bad, it's because I'm french ;)

share|improve this question

just use an .vbs file (in notepad: save as all -> invisible minecraft start.vbs) :

Set WshShell = CreateObject("WScript.Shell") 
WshShell.Run chr(34) & "C:\minecraft.bat" & Chr(34), 0
Set WshShell = Nothing

and make an batchfile you want to call : minecraft.bat

START "minecraft" /high /wait "C:\Program Files\Java\jre7\bin\javaw.exe" -Xms1024m -Xmx2048m -cp "%APPDATA%\.minecraft\bin\minecraft.jar;%APPDATA%\.minecraft\bin\jinput.jar;%APPDATA%\.minecraft\bin\lwjgl.jar;%APPDATA%\.minecraft\bin\lwjgl_util.jar" -Djava.library.path="%APPDATA%\.minecraft\bin\natives" net.minecraft.client.Minecraft <username> <password>

of course, change to the username and to password

save these 2 in C:\ and make an link from the invisible mminecraft start to your desktop. that's all...

this will help you, but your friend has to update java from

ps. if MY english is bad, i am dutch...

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .