First post, by Binarypasta
Hey everybody, i tried to make a quick-launch script, as i did as a kid. However, i kind get the "Choice" command to work, and neither the "Set". (The set is not listed in the wiki as a legal command, so i'm not to surprised there)
EDIT: This is of course for a DOSBox specific setup, not the windows command-line.
How would i go around to do this then? Is there something i have set up wrong, the choice works perfectly in the windows cmd. (Thou i don't remember using that command ever before)
Here's my code so far:
(With stylish written menu, done in ECHO, but I've excluded that from here, as it works fine.)
CHOICE /C 123456789 /M "Enter your choice:"
REM - List errorlevels in decreasing order.
IF ERRORLEVEL 9 GOTO End
IF ERRORLEVEL 8 GOTO End
IF ERRORLEVEL 7 GOTO End
IF ERRORLEVEL 6 GOTO End
IF ERRORLEVEL 5 GOTO End
IF ERRORLEVEL 4 GOTO BAT4
IF ERRORLEVEL 3 GOTO BAT3
IF ERRORLEVEL 2 GOTO BAT2
IF ERRORLEVEL 1 GOTO BAT1
:BAT1
start bstone.bat
GOTO End
:BAT2
start supaplex.bat
GOTO End
:BAT3
start jazz.bat
GOTO End
:BAT4
start raptor.bat
GOTO End
:End
cd..
And here's what i've tried with the SET command, if that can help me get further:
SET /P M=Type 1, 2, 3, 4, 5, 6, 7, 8, 9, e, or E then press ENTER:
REM - This is the input directioner.
IF %M%==1 GOTO BAT1
IF %M%==2 GOTO BAT2
IF %M%==3 GOTO BAT3
IF %M%==4 GOTO BAT4
IF %M%==5 GOTO BAT5
IF %M%==6 GOTO BAT6
IF %M%==7 GOTO BAT7
IF %M%==8 GOTO BAT8
IF %M%==9 GOTO BAT9
IF %M%==e GOTO End
IF %M%==E GOTO End
:BAT1
start bstone.bat
GOTO End
...