Jump to content

All my products and services are free. All my costs are met by donations I receive from my users. If you enjoy using any of my products, please donate to support me. My bare hosting costs are currently not met so please consider donating by either clicking this text or the Patreon link on the right.

Patreon

Recommended Posts

Posted

I have a number of PC Games where the ISO is required in the machine to launch the game. i.e. Legit games without a NoCD Crack :)

For Example I have "Battlefied 1942" which is installed but requires the CD to run.

I tried to use the ISO Mounter facility in GameEx but I couldn't really find any information on it so I created a batch file (my new friends) to do the job.

Maybe it will be of use to someone else...

1. There is a Tutorial on this site on how to set up PC Games on GameEx here entitled "Setting up PC Games" which I followed - so I my Rom Filter is set up for look for "*.lnk" files as shown there.

2. In the Emulator config page I have the have the "Rom Path" set to "Y:\PCGames\Shortcuts" which is where all of my PC Game shortcuts (*.lnk files) are located.

3. Not set up on the emulator page but seperately I have a folder with any ISO, IMG, BIN files that I might need to mount the game disks. In my case "Y:\PCGames\Games_Windows_ISOs".

4. In the emulator config page I have and entry in "Launch Before" as follows:

call "Y:\PCGames\Startup Windows Games.bat" "[ROMFILE]"

5. The bat file that I run in step 4 is attached (just rename from .txt to .bat and contains the following contents:

REM @echo off

cls

echo.

SET INPUT1=%1

SET ROMFile=%INPUT1:~1,-1%

Echo Romfile: %ROMFile%

set str=%ROMFile%

echo.

set str=%str:.lnk=%

echo str: %str%

SET mounter=C:\Program Files (x86)\Elaborate Bytes\VirtualCloneDrive\vcdmount.exe

SET isopath=Y:\PCGames\Games_Windows_ISOs

echo %mounter%

echo %isopath%

If EXIST "%isopath%\%str%.ccd" (goto isCCD)

If EXIST "%isopath%\%str%.cue" (goto isCUE)

If EXIST "%isopath%\%str%.iso" ("%mounter%" "%isopath%\%str%.iso")

If EXIST "%isopath%\%str%.bin" ("%mounter%" "%isopath%\%str%.bin")

If EXIST "%isopath%\%str%.img" ("%mounter%" "%isopath%\%str%.img")

goto Exit

:isCUE

"%mounter%" "%isopath%\%str%.cue"

goto Exit

:isCCD

"%mounter%" "%isopath%\%str%.ccd"

goto Exit

:Exit

ping -n 5 127.0.0.1 >NUL

What the bat file will do is take the name of the Rom file (i.e. Battlefield 1942.lnk) and strip the file extension from it (".lnk").

It will then look for ISOs or BINs or whatever you add to the code and if the Drive images exist in the folder specified it will mount them, wait a few seconds then exit.

Lines you may need to change to suit your needs:

C:\Program Files (x86)\Elaborate Bytes\VirtualCloneDrive\vcdmount.exe - This is the path to your drive image mounting software (I use Virtual Clonedrive which incedentally does not launch .cue files although they are included in the code).

You can change replace this with Daemon Tools if you use that.

For Example:

C:\Program Files (x86)\DAEMON Tools Lite\DTLite.exe

Note if there are additional parameters then you will need to add these after each "%mounter%" entry in the BAT file and may need to add a Device first (depending how you have DT setup..

For Example:

If EXIST "%isopath%\%str%.iso" ("%mounter%" -mount dt,0,"%isopath%\%str%.iso")

Y:\PCGames\Games_Windows_ISOs - This is the folder where it will check whether there are any related disk image files named (for example) Battlefield 1942.iso or Battlefield 1942.img or Battlefield 1942.bin. If there isn't a related disk image it will just exit.

ping -n 5 127.0.0.1 >NUL - This line will wait a few seconds to allow the drive to mount before it launches the game. Increase or reduce the "5" parameter to extend or reduce the delay.

Notes:

- I have set up the Bat file to first search for .cue or .ccd files as these need to be mounted instead of the related BIN, ISO file if the disk has music on it for example.

- When mounting disks Windows can give an annoying Autoplay Popup. You can disable this completely by going into "Control Panel > Autoplay" and unchecking the box "use Autoplay for all media and devices".

Hope it's of use to others!

Startup Windows Games.txt

Posted

For mounting iso's I tend to use deamon tools lite example of my simple bat file for a good old pc game Perimeter is

"C:\Program Files (x86)\DAEMON Tools Lite\DTLite.exe" -unmount_all

"C:\Program Files (x86)\DAEMON Tools Lite\DTLite.exe" -mount scsi, 0, "C:\crazybox\Roms\pc strategy\data\Perimeter_Gold\pgold.mdf"

cd "C:\crazybox\Roms\pc strategy\data\Perimeter_Gold\game files\PGW\"

perimeter.exe

Hit a snag with a couple which require changing CD's but applied the same simple bats and used autohotkey to assign ctrl+alt+1 , 2, 3, etc to load each CD.

Would your Method be better in the long run?

  • 2 weeks later...
Posted

For mounting iso's I tend to use deamon tools lite example of my simple bat file for a good old pc game Perimeter is

"C:\Program Files (x86)\DAEMON Tools Lite\DTLite.exe" -unmount_all

"C:\Program Files (x86)\DAEMON Tools Lite\DTLite.exe" -mount scsi, 0, "C:\crazybox\Roms\pc strategy\data\Perimeter_Gold\pgold.mdf"

cd "C:\crazybox\Roms\pc strategy\data\Perimeter_Gold\game files\PGW\"

perimeter.exe

Hit a snag with a couple which require changing CD's but applied the same simple bats and used autohotkey to assign ctrl+alt+1 , 2, 3, etc to load each CD.

Would your Method be better in the long run?

Hi

It works well for me but I am now leaning towards DTLite as well simply because there is so much more compatibility with things link MDF, MDS etc.

The key feature I wanted is to ensure that it is intelligent enough to mount a cue instead of a bin for example. In game music can be important.

I also wanted to make sure that it could be run for PC Games whether they have a CD to mount for a particular game or not.

For this I think it works quite well.

I will re-write this today for DTLite in mind and test...

I'll repost when tried and tested.

Cheers

Posted

Moved to the User Projects forum. ;)

Posted

I have re-written for Daemon Tools Lite. Here is the code for the batch file.

Just copy into a text file and rename to Startup Windows Games.bat or whatever you like:

@echo off

cls

echo.

SET INPUT1=%1

SET ROMFile=%INPUT1:~1,-1%

set str=%ROMFile%

set str=%str:.lnk=%

If EXIST "%programfiles%\DAEMON Tools Lite\DTLite.exe" (SET mounter="%programfiles%\DAEMON Tools Lite\DTLite.exe")

If EXIST "%programfiles(x86)%\DAEMON Tools Lite\DTLite.exe" (SET mounter="%programfiles(x86)%\DAEMON Tools Lite\DTLite.exe")

SET isopath=Y:\PCGames\Games_Windows_ISOs

If EXIST "%isopath%\%str%.ccd" (goto isCCD)

If EXIST "%isopath%\%str%.cue" (goto isCUE)

If EXIST "%isopath%\%str%.mds" (goto isMDS)

If EXIST "%isopath%\%str%.iso" (%mounter% -mount dt,0,"%isopath%\%str%.iso")

If EXIST "%isopath%\%str%.bin" (%mounter% -mount dt,0,"%isopath%\%str%.bin")

If EXIST "%isopath%\%str%.img" (%mounter% -mount dt,0,"%isopath%\%str%.img")

goto Exit

:isCCD

%mounter% -mount dt,0,"%isopath%\%str%.ccd"

goto Exit

:isCUE

%mounter% -mount dt,0,"%isopath%\%str%.cue"

goto Exit

:isMDS

%mounter% -mount dt,0,"%isopath%\%str%.mds"

goto Exit

:Exit

ping -n 9 127.0.0.1 >NUL

Just ensure you:

1. Set "Launch Before" to point at the Bat File like so:

call "Y:\PCGames\Startup Windows Games.bat" "[ROMFILE]"

2. Change the isopath setting to point at the folder where you store your CD images for the related .lnk files.

3. I have found the delay of 9 in this line to be about 4/5 seconds which is about right:

ping -n 9 127.0.0.1 >NUL

4. If you happen to have any NRG drive images or any other format just add more lines like so:

If EXIST "%isopath%\%str%.nrg" (%mounter% -mount dt,0,"%isopath%\%str%.nrg")

Hope it's of some use.

Works for me!

Guest
This topic is now closed to further replies.
×
×
  • Create New...