Stockholm, Sweden, Europe, Earth Interests: Old games & young women
Vaelor wrote:
I notice your profile says you're the DOSBox author - perhaps you might be able to tell me, is loading games this way, with a seperate config and autoexec for each game I want to run, the best way to use DOSbox from the command line?
But Qbix is using Linux so he is a little handicapped when it comes to Windows and how it handles command lines 😁
I have developed a very standard way of running games with DOSBox 0.65. A Run.cmd file to launch DOSBox, and game-specific dosbox.conf file overrides the default 0.65 values. It goes like this:
1@ echo off 2 3 if not defined dosbox ( 4 set dosbox=%ProgramFiles%\DOSBox-0.65\dosbox.exe 5 ) 6 7 if not defined unpacker ( 8 set unpacker="%ProgramFiles%\7-Zip\7z.exe" x -o"Unpacked" 9 ) 10 11 if not exist "capture" mkdir "capture" 12 if not exist "C-drive" mkdir "C-drive" 13 if not exist "Unpacked" %unpacker% "download.zip" 14 15 start "DOSBox" "%dosbox%" -noconsole %*
(if you have the game on a CD simply comment-out the if not exist "Unpacked" %unpacker% "download.zip".
In the same directory as the Run.cmd file, I have the dosbox.conf file. It generally follows this outline:
1# DOSBox 0.65 configuration for "Game-name" by Publisher, Year. 2# 3# By MiniMax 4 5[cpu] 6cycles=10000 7 8[render] 9scaler=normal3x 10 11[autoexec] 12@ echo off 13 14rem +--------------------------------------------------------------- 15rem ! Mount the virtual harddisk and the CD-drive. 16rem +--------------------------------------------------------------- 17 18 mount C "C-drive" 19 mount D "Unpacked" -t cdrom 20 21rem +--------------------------------------------------------------- 22rem ! Check for FreeDOS Keyboard handler and select an enhanced (/E) 23rem ! Danish (DK) keyboard with codepage 850. 24rem +--------------------------------------------------------------- 25 26 if exist C:\FreeDOS\KeyB.Exe C:\FreeDOS\KeyB.Exe DK,850 /E 27 28rem +--------------------------------------------------------------- 29rem ! Are we ready to run the game, or should we try to install it? 30rem +--------------------------------------------------------------- 31 32 if exist C:\GAME\Game.Bat goto Ready 33 if exist D:\Install.Exe goto Install 34 goto Done 35 36:Install 37 38rem +--------------------------------------------------------------- 39rem ! Switch to the CD-ROM drive, and inform the user about which 40rem ! command to use for installing the game. 41rem +--------------------------------------------------------------- 42 43 D: 44 echo. 45 echo Type INSTALL to start the game. 46 goto Done 47 48:Ready 49 50rem +--------------------------------------------------------------- 51rem ! Switch to the harddisk , and inform the user about which 52rem ! command to use for running the game. 53rem +--------------------------------------------------------------- 54 55 C: 56 cd \GAME 57 echo. 58 echo Type GAME to start the game. 59 goto Done 60
…Show last 2 lines
61:Done 62 echo on
DOSBox 0.65 follows these rules when it starts:
1. Create internal configuration.
2. Override it with the one specified by -conf
If there is none at step 2, then
3. Check current directory for dosbox.conf.
If none is found at step 3, then
4. Check %HOME% for dosbox.conf.
My method has no -conf and solely relies on step 1 and 3.