Importing Music: Unreal Tournament 3 - Part 1

1: Getting Started
2: Sound Controls and Cues
3: The Music Arrangement
4: Cooking a Final Package
5: Quick Reference Guide

This guide is aimed at musicians who wish to import their own music into Unreal Engine 3 games (Unreal Tournament 3) or level designers who have received music segments from a musician to import themselves. The Looping Music tutorial may aid the musician in creating seamless music loops in preparation for importing. It is also recommended to review the Music Cues Explained tutorial series to gain a better knowledge of how Unreal Tournament 3 will use the music once it has been imported. There is also a less in depth video tutorial here . It is very important to note that the Playstation 3 version of Unreal Tournament 3 does not support custom audio. Playstation 3 uses a proprietary version of ATRAC3 to render audio. At this time the consumer version of the Unreal Editor does not have the required tools or codec to encode audio into this format. While PC versions may be created with custom audio, PS3 versions must have all custom audio removed or replaced before it can be converted.

Custom music in modifications of any kind is uncommon and unforunately low priority for many developers but when done right can greatly add to the player's experience and create a unique and memorable environment the player is likely to remember. By nature we rely mostly on sight and for the most part would easily recall an event if shown an image that was somehow related to it but this requires a distraction from whatever we may be doing in our busy lives to look away and focus our attention on this visual reminder. Music is something that can be enjoyed in practically every task. It doesn't require our full attention nor does it need to even be a distraction. We are all likely familiar with the music of Super Mario Bros and could easily associate the music from World One, the underground levels, water world and bowser battles. Halo is another great example as the main themes used in the menu are unmistakable. The Unreal flyby also has a place for anyone who's played Unreal. The point being is that if we heard any of these pieces while going about our every day lives it's easy to relive our experience without having to be distracted from the task at hand. Very few developers realize the impact custom music would have on their project. While it may do fine without, using unique and well written music adds a signature touch that is unmistakable.

Lets's get started

To anyone with little to no experience with the current or past versions of the Unreal Editor, the complexity of the program along with the absence of any official or complete documentation on importing music can be very discouraging. Fortunately though there are many steps to take while importing music they are logical and not very time consuming once you understand them. Unreal Tournament 3 creates two main directories; a program directory found in \Program Files\Unreal Tournament 3\ and a user directory typically found in \My Documents\My Games\Unreal Tournament 3\. The first thing we need to do is copy all the audio we're going to be importing into a folder inside the user directory. Make sure all your audio is redbook wav (16bit stereo 44100Hz PCM) and copy it into \My Documents\My Games\Unreal Tournament 3\UTGame\Unpublished\CookedPC. Once that's been done it's time to start UnrealEd. This can be done several ways. Navigate to the program directory (\Program Files\Unreal Tournament 3\) and inside the folder Binaries doubleclick UnrealFrontend.exe. It may be easier to create a shortcut to this for future use.

After the frontend has started ensure that along the top the Platform  is PC and Game is UTGame then click Editor. After it loads you should see a main window for 3D level editing partially covered by a Generic browser window. In this browser window click File and Import. You'll be given an Open prompt to select your audio from. If not already, navigate to the folder where you copied the music to and ctrl-click all of you music segments, don't click any stingers quite yet. Once all your music segments are highlighted click Open. A window like the one below will open.


For the Package name it's best to pick something unique so no conflicts occur (conflict: two or more files having the same name). We're going to be creating groups which will let us quickly sort items while working on other tasks later. Since these are music segments why not call the group MusicSegments. Once that is done check the box next to bAutoCreateCue and uncheck bIncludeAttenuationNode. After that just click OK To All. On the left side of that browser you should see a list of packages and a scrollbar. Use that to locate the package you just created. The rest will be greyed out while yours will be dark and have a star ( * ) next to it. The star indicates the package has been modified and not yet saved. Packages in bold indicate they are "Fully Loaded" or every asset in that package has been loaded into memory. After you click it you should see a list of items you imported and created appear in the right pane of the browser. There are twice as many items in here because a Cue was created for each music segment you imported. The music segments have been given the label USound and right now all the USounds are highlighted. Go ahead and right click on the first USound and then click properties. USounds contain the audio data and are compressed with ogg vorbis when a final package is made. On this properties window we have control over how much compression is used and how it will be decompressed in the game. Most of the music that shipped with Unreal Tournament 3 was compressed with settings from 40 to 60. The audio quality ranges from acceptable to great depending on who you ask and the resulting filesize is what's to be expected from compressing your music with an external encoder. In short UnrealEd does a fine job encoding audio and following Epic's example it is perhaps best to enter a number from 40 to 60 in the CompressionLevel field. Another thing we want to do here is check the box above that says bForceRealtimeDecompression. I have no technical explanation other than this continues to follow Epic's example.
After you've set the compression for your music segments it's time to import your stingers. Again go back to File and Import. This time ctrl-click all your stingers and then click Open. When the import box opens again make sure you're using the same Package Name. Since these are stingers for the Group let's enter MusicStingers. Again check bAutoCreateCue and uncheck bIncludeAttenuationNode and click OK To All. This time all the stingers will be highlighted in the right pane. Right click the first highlighted stinger and click properties. Chose a compression level between 40 and 60 and check bForceRealtimeDecompression.
 
*It should be noted that the music can be previewed in the Editor by double-clicking the USound or the USound Cue but it is highly recommended to avoid doing so until after the compresion settings have been entered. Playing audio before the compression has been set will force the sound to use the default compression settings which may not be ideal. To change the compresion settings after the sound has been played requires the sound to be reimported.
 
<< 1 2 3 4 5 >>