Emulator option to set current directory to the ROM directory

Issue #6915 new
Paul Galbraith created an issue

This request is for DOSBox and DOSBox-X emulators and others like them, where you often create a custom configuration file for each game. It’s convenient to store the config file and the DOS game files all in a single parent directory, and then launch DOSBox-X by pointing to the config file and treating that as your “ROM” file in LaunchBox. It would be very convenient, as well, if LaunchBox had an emulator-level option to say “run from the ROM directory” so that LB would change the current directory to the ROM location, prior to executing the emulator. That way, in the DOSBox config file, when you’re referring to media such as game ISO files, DOSBox will find them in the current directory as one would naturally expect. Let me give an example:

Let’s say you have a directory structure like this:

C:\LaunchBox\Emulators\DOSBox-X\dosbox-x.exe          (the emulator binary)
C:\LaunchBox\Games\MS-DOS\mydosgame\dosbox-x.conf     (DOSBox-X config for this game)
C:\LaunchBox\Games\MS-DOS\mydosgame\mydosgame.iso     (CD-ROM image)
C:\LaunchBox\Games\MS-DOS\mydosgame\VirtualHD\*       (main location for game files)

In your DOSBos-X config file, the “natural” thing to do would be to mount VirtualHD as drive C and mydosgame.iso as drive D. However, because of the way LaunchBox does things, this doesn't work. LaunchBox sets the current directory to the emulator location (i.e. C:\LaunchBox\Emulators\DOSBox-X), so in your game config you have to mount ..\..\Games\MS-DOS\mydosgame\VirtualHD and ..\..\Games\MS-DOS\mydosgame\mydosgame.iso instead, which is really unintuitive, and to add more pain, means that LaunchBox really needs it's own config file that is separate and different from the one you would normally use if you are running DOSBox-X the "normal" way (i.e. outside of LaunchBox).

Having an emulator option to instruct LB to change directory to the ROM directory first, before executing the emulator, would solve this.

Comments (4)

  1. Paul Galbraith reporter

    This would also allow VICE emulator fliplist (.vfl) files to be portable, as it stands with LaunchBox right now you have to explicitly specify a fully qualified filename with drive and directory for each rom file in a fliplist, rather than being able to specify portable names (i.e. without drive/directory hard coded).

  2. Log in to comment