Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.
He's playing a game called IRL. Great graphics, *censored* gameplay.
@echo offmode con cols=22 lines=2title CONTROLLERecho Type in EXIT to exit.pause > nulclsecho Press ENTER to skip.pause > nul:looperclsset input=skipset /p input=if /i not "%input%"=="exit" (tskill mplayer2) else (del music.files & tskill mplayer2 & tskill cmd)goto looper
@echo offstart cmd.exe /k "%cd%\controller.bat"echo %1for /f "tokens=*" %%A in ("%1") do set pth=%%~dpAsetlocal enabledelayedexpansionif exist music.file* del music.file*dir /b "%pth%\*.mp3" > music.files.tempset counter=1for /f "delims=" %%a in (music.files.temp) do (echo !counter! %%a >> music.filesset /a counter+=1)del music.files.tempset lastsong=:loopset /a mus=%random%%%counter%for /f "tokens=1*" %%b in (music.files) do (if %%b==!mus! if "%%c"=="!lastsong!" goto loopif %%b==!mus! start /min /wait "" "C:\Program Files\Windows Media Player\mplayer2.exe" /play /close "!pth!\%%c" & set lastsong=%%c)goto loop
... and finally, how do you call this first batch? From the command line? And how does the mysterious %1 parameter get created? Is that typed after the batch name?
Why don't you just do this?set pth="%~dp1"
I did that at one point in time...I just can't quite remember why I changed it...anyway, did you figure out why controller.bat is crashing?
start cmd.exe /k "%cd%\controller.bat"
start "" "cmd /k controller.bat"
'controller.bat" ' is not recognized as a ... you know the rest.