Difference between revisions of "GUS Music in Dosbox"

From UFOpaedia
Jump to navigation Jump to search
m
Line 21: Line 21:
 
== Setting up Dosbox with the GUS patches==
 
== Setting up Dosbox with the GUS patches==
  
* Unpack the patches and you should get two folders: '''ULTRASND411''' and '''ULTRASNDPPL161'''. Pick one to use, either will work fine.  
+
* Unpack the patches and you should get two folders: '''ULTRASND411''' and '''ULTRASNDPPL161'''. Pick one to use, either will work fine. The difference will be in the sound of some instruments.  
 
** Optional: Keep them as they are or rename the one you want to use to '''ULTRASND'''  
 
** Optional: Keep them as they are or rename the one you want to use to '''ULTRASND'''  
  
Line 48: Line 48:
 
* Run SETUP.EXE. When it loads, you will be asked to set the sound card for both the sound effects and music output. Use the cursor keys an enter key to navigate through the options.  
 
* Run SETUP.EXE. When it loads, you will be asked to set the sound card for both the sound effects and music output. Use the cursor keys an enter key to navigate through the options.  
  
* The first card to set up is the sound output. Set it to either '''Soundblaster''' (8-bit mono), '''Soundblaster Pro''' (16-bit stereo) or even select the '''Gravis Ultrasound'''. For Soundblasters, you will need the port, IRQ and DMA to be set. Dosbox normally uses Port:220, IRQ: 7, DMA: 1.  
+
* The first card to set up is the sound output. Set it to either '''Soundblaster''' (8-bit mono), '''Soundblaster Pro''' (16-bit stereo) or even select the '''Ultrasound''' / ''Gravis Ultrasound'''. For Soundblasters, you will need the port, IRQ and DMA to be set. Dosbox normally uses Port:220, IRQ: 7, DMA: 1.  
 
** Next you will be asked to set the max number of channels. This refers to how many sound effects can play at the same time. If you find you get very loud bursts of gun fire sounds during the alien turn, set this to a lower setting such as 4. The loudness is caused by lots of instances of the same sound effect being played at the same time.  
 
** Next you will be asked to set the max number of channels. This refers to how many sound effects can play at the same time. If you find you get very loud bursts of gun fire sounds during the alien turn, set this to a lower setting such as 4. The loudness is caused by lots of instances of the same sound effect being played at the same time.  
 
** If asked to swap your audio, set it to NO unless your sound effects are reversed.  
 
** If asked to swap your audio, set it to NO unless your sound effects are reversed.  
  
* You will now get to the Choose Music Board screen. Select '''Gravis Ultrasound'''. When you hit enter, SETUP.EXE will close and save your settings.  
+
* You will now get to the Choose Music Board screen. Select '''Ultrasound''' / '''Gravis Ultrasound'''. When you hit enter, SETUP.EXE will close and save your settings.  
  
 
Now when you launch the game, it will run with the new settings. If not, go back into the sound setup and make further adjustments as needed.  
 
Now when you launch the game, it will run with the new settings. If not, go back into the sound setup and make further adjustments as needed.  

Revision as of 00:43, 18 August 2013

Very rough page outline on how to make the midi music in dos versions of UFO/TFTD sing with the help of Dosbox's Gravis Ultrasound emulation.

Dosbox, which X-COM UFO and Terror From the Deep rely on to run their original Dos versions on modern day computers, is able to emulate the Gravis Ultra Sound. However, due to incompatibilities in licenses, does not come packaged with GUS patches by default. Attempting to play audio through GUS emulation will generally result in silence until sound patches are provided.

What is GUS?

The Gravis Ultra Sound or GUS was a sound card that is able to used samples of real world sounds for its instruments, allowing for rich playback of MIDI music.

For more information on this sound card and its eventual demise you can refer to the Gravis Ultrasound article on Wikipedia.

GUS Patches

Refer to huggybaby2's ready-to-use Ultrasnd folders:

http://www.dosgames.com/forum/about10574.html

Obtain a copy of the pre-compiled patches in the post above. Instructions on how to set it up are available there, alternately follow the instructions here.

Note: For those concerned with the legality of obtaining the patches, the GUS patches are available to download via the Gravis FTP site. The file you can get through the above link has the patches pre-compiled and ready to go.

Setting up Dosbox with the GUS patches

  • Unpack the patches and you should get two folders: ULTRASND411 and ULTRASNDPPL161. Pick one to use, either will work fine. The difference will be in the sound of some instruments.
    • Optional: Keep them as they are or rename the one you want to use to ULTRASND
  • Store these folders somewhere. If you have your Dos game stored in a folder, say DOSGAMES\, copy them into there. Alternately, copy them directly into the same folder as the game you want to use the patches with.
  • Keeping the patches in the same folder as your game means less mounting or complicated file paths, but requires that you make copies of the patches for each game.
  • Keeping the patches in a separate folder will require that you either keep them in the folder that Dosbox will mount as your C:, or you can get Dosbox to mount a new drive just for the patches. Either way, make sure you know what path Dosbox will need to be able to find the patches.
  • The next step is to alter Dosbox's configuration file to enable its GUS support. For a normal Dosbox configuration, you can edit the main Dosbox .conf file. If you have a special .conf file made specifically for your game or have downloaded a game from a place like Steam or GOG with the game pre-packaged with a copy of Dosbox, you will need to open its respective .conf file.
  • When editing the Dosbox .conf file, go to the [GUS] heading
  • Alter the line gus=false to gus=true if it isn't already set.
  • Alter ultradir=C:\ULTRASND and point it to the directory where you can find the patches.
Note: You can also use the SET command to set this environment variable from the Dosbox command line interface or enter it into the [autoexec] section at the end the .conf file.

This will set up your copy of Dosbox to use its GUS emulation with games that support it.

Setting up UFO/TFTD to use the GUS

TODO

  • Screenshots!

Now that Dosbox is set up to use the GUS, the last step before you can make use of it is to set up UFO/TFTD to use it. To do this, you need to run the SETUP.EXE file in the game directory to access the game's sound card settings.


  • Run SETUP.EXE. When it loads, you will be asked to set the sound card for both the sound effects and music output. Use the cursor keys an enter key to navigate through the options.
  • The first card to set up is the sound output. Set it to either Soundblaster' (8-bit mono), Soundblaster Pro (16-bit stereo) or even select the Ultrasound / Gravis Ultrasound. For Soundblasters, you will need the port, IRQ and DMA to be set. Dosbox normally uses Port:220, IRQ: 7, DMA: 1.
    • Next you will be asked to set the max number of channels. This refers to how many sound effects can play at the same time. If you find you get very loud bursts of gun fire sounds during the alien turn, set this to a lower setting such as 4. The loudness is caused by lots of instances of the same sound effect being played at the same time.
    • If asked to swap your audio, set it to NO unless your sound effects are reversed.
  • You will now get to the Choose Music Board screen. Select Ultrasound / Gravis Ultrasound. When you hit enter, SETUP.EXE will close and save your settings.

Now when you launch the game, it will run with the new settings. If not, go back into the sound setup and make further adjustments as needed.


Running SETUP.EXE through Dosbox

SETUP.EXE will very likely not be able to run natively on modern operating systems. To bypass this, you can run it through Dosbox.

For those that mainly use Dosbox through its command line console, just go to your UFO/TFTD directory and run SETUP directly.

If your version is all set up to run the game through Dosbox transparently, such as the Steam version, you will need to make some temporary alterations to the .conf file.

Go to your .conf file's [autoexec] section.

The second-to-last line will typically have the command to launch the game, either ufo or ufo.bat for Enemy Unknown/UFO Defense and terror or terror.com for TFTD. For those that have set up the .conf file to use XCOMUTIL, this will be runxcom.bat. The last line will have Exit.

We need to alter these line slightly so that the .conf file launches the sound setup or the command line console instead.

Start by adding the word REM in front of the line that launches the game. REM means REMark, it turns the line into a comment and the line will have no effect when Dosbox runs it.

From here, if you would prefer to work from the command line console, REM out the exit as well and save the .conf file. Once you have run the sound setup, go back and edit .conf file again and remove the lines you REM'd out.

If you want to just launch the sound setup directly and bypass the console, REM out the line that runs the game and insert a new line before or after it and and type setup. Now save the .conf file. Launching the game now will load the sound setup instead of the game. When you are done, go back into the .conf file, delete or even REM out the line to run the setup and remove the REM from the line that runs the game and save.

Finishing up

With everything set up, the game will now start playing midi music via GUS emulation. Enjoy the difference. Note that one negative side effect of using the GUS is that the game may take a few seconds longer to start than usual as it needs to load the audio patch. A small price to pay for improved audio instruments.

Note that if you have any other Dos games that can take advantage of the GUS, you can adapt the procedures mentioned above.