Jump to content
LaunchBox Community Forums

In the DOSBox config, how do I mount a folder as a CD drive while also keeping it portable?


PurpleTentacle

Recommended Posts

Solved it, but I'm leaving this up in case anyone needs it. The command mount A "GazCD\" -t cdrom worked. For some reason, I thought I tried that, but I guess I didn't.

 

 

So I have Windows 3.1 in LaunchBox, and it uses a bat file with the following commands:

 

@echo off
dosbox -conf dosbox.play.conf

 

That config file has "mount C C" in its commands to mount the root directory as the C drive, and then it launches Windows 3.1. 

 

Now the problem I'm having is that a program that I've downloaded (Gazillionare) thinks the CD drive is the A drive, so it checks that & fails, since there is no A drive (I can't reinstall it, unfortunately). Now, I've gotten this to work by using the "-t cdrom" command & specifying a directory that has the CD files in it, but the problem is that the path is specific, meaning that if I move Launch Box to another computer, it won't work.

 

Specifically, the command is


mount A C:\Users\usernamehere\LaunchBox\Games\Windows3\DOSBox-Win31\CD -t cdrom

 

How do I write the command so that it looks in that CD directory relative to the root directory? The original config file has #mount D "CD\" in it, but even after removing the # & switching the D to A, it doesn't work. I had assumed that "CD\" would make it relative, but that doesn't work. 

 

**EDIT:** Just wanted to mention that the DOSBox that's being used in this situation is contained within the directory, "DOSBox-Win31", and not the DOS Box in LaunchBox, so any folder mounted is relative to that directory, not the LaunchBox one. I also tried to mount the folder from within LaunchBox & use the copy of DOSBox from within LaunchBox, and while I can get Windows 3.1 to run, the drive doesn't mount.

 

 

Edited by PurpleTentacle
Link to comment
Share on other sites

  • 3 months later...

Sorry for the super late reply, but relative paths are usable in DOSBox .confs. They're relative to DOSBox's location.

.\ = DOSBox's folder
..\ = Up one folder from DOSBox's folder
..\..\ = Up two folders from DOSBox's folder
etc.

So let's say DOSBox is located in C:\DOSBox and your game (we'll use Dreamweb as an example) is in C:\DOSBox\Games\Dreamweb

mount c ".\Games\Dreamweb"

...would mount that folder as your C drive.

If you wanted to mount a specific subfolder as a cd drive, the same rules apply. You can also do this with disc images, so you could do something like:

mount c ".\Games\Dreamweb"
imgmount d ".\Games\Dreamweb\Disc Image\Dreamweb.iso" -t cdrom (or -t iso)

If it wasn't located in DOSBox's folder, you'd just need to adjust the paths upwards to the point that it was an accessible subdirectory. It does have to be on the same hard drive as DOSBox.

Let's say your folders are:

C:\Emulation\DOS\Emulators\DOSBox\
C:\Emulation\DOS\Games\Dreamweb\

You'd just use:

mount c "..\..\Games\Dreamweb"

etc.

Using relative paths, you can move the folders wherever you want, so long as DOSBox's location is moved along with them. This is essentially how all the DOS stuff I have on Zomb's Lair works, DOS games on GOG, etc. They use a predesigned structure that contain the game and a copy of DOSBox, which means you can take the folder that contains both of them and move it wherever you want, and the path structure will remain intact, because they're still the same, relative to each other.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...