This is a guide for installing the UGX Jukebox to your map. Note that the UGX Jukebox is (will be) also included with UGX Mod v1.1+ for automatic installation.
NOTE: Before reading this guide, determine where your World at War root directory is located.
Non-Steam Install: C:\Program Files (x86)\Activision\Call of Duty World at War\
Steam Install: C:\Program Files (x86)\Steam\steamapps\common\Call of Duty World at War\
For the rest of this guide, it will be assumed that the word "root" refers to the appropriate installation path shown above.
Say 'Yes to all' if Windows asks you about replacing files when dragging files into your root directory.
Download the UGX Jukebox installation files here: UGX Jukebox v1.0.4.rar (25.1MB)
Extract the archive to it's own folder anywhere using WinRAR or equivalent.
Navigate into the mods/ folder and rename the MAPNAME folder to the name of your map's folder in your root directory (example: nazi_zombie_testmap)
The first step to installing the Jukebox is adding the files to your root directory. highlight the "map_source", "mods", "raw", and "sound_assets" folders from the archive and drag them into your root directory. It should merge with your existing folders. If not, you did it wrong!
You need to add two lines to your mapname.gsc before the Jukebox will run.
NOTE: "mapname.gsc" refers to your map's main gsc file, which is named the same name as your map.
For example, a map called "nazi_zombie_example" would have a mapname.gsc named "nazi_zombie_example.gsc". This file is commonly used to call custom scripts for a map.
Lines which precache items such as models need to be called BEFORE the gamestate starts and should not be threaded. Lines which do not precache any items should be called AFTER the gamestate starts and should be threaded.
The gamestate is started by this line in mapname.gsc:
To add lines to your mapname.gsc:
The Jukebox has some basic configuration settings that can be changed if you wish. The default settings do not require the power switch to be on for the Jukebox to work, and charge 10 points per song play.
Changing this setting to true will display a "Power must be on." message to players until the power switch is flipped in the map, preventing players from using the Jukebox until the power is on.
Changing this setting will change the amount of points players are charged each time they play a song from the Jukebox.
To place one or more Jukeboxes in your map, use the prefab root/map_source/_prefabs/ugx_mod/ugx_jukebox.map.
NOTE: "Prefab" is shorthand for "prefabrication". A prefab is a pre-assembled group of brushes, models, or terrain patches which can be placed and moved as a group in Radiant.
To Place a Prefab:
Once you have done the above steps, you are ready to finalize the installation. If you would like to add custom songs to your Jukebox, read section 3 before completing this step. To finalize your installation of the Jukebox, complete the following steps:
Check the box for animscripts/jukebox_animscript.gsc in the files list on the right side.
Check the box for animtrees/_jukebox.atr in the files list on the right side.
Check the boxes for the following image files in the files list on the right side:
Check the box for maps/ugx_jukebox.gsc in the files list on the right side.
Check the box for weapons/sp/jukebox_button_press in the files list on the right side.
Check the boxes for "Build mod.ff fastfile" and "Build IWD"
Click the "Build MOD" button.
You are finished! You can now boot your map and enjoy the UGX Jukebox.
If you plan to use your own songs in the Jukebox instead of the default non-copyright songs, you will need to convert them. Later we will have a page which teaches you all about converting sounds and creating soundaliases - but until then, you're on your own. The process is the same as you would use for any other music box. If you have already converted some songs for use with a different music box script, you may reuse them without changing anything.
To add your custom songs to the Jukebox, you first need to open root/mods/MAPNAME/maps/ugx_jukebox.gsc.
Inside the jukebox_settings() function, you will find the default songs defined on line 19. There is a function called add_song() which adds songs to the Jukebox and its menu.
The first argument is the song's display name which shows on the Jukebox menu. The second argument is the soundalias name, which is the soundalias name that corresponds to the display name. Replace the default songs on line 19 with your own. The Jukebox menu will only display a maximum of 10 songs, regardless of how many you add in the script file. This limit is imposed mainly because it is an inconvenience to players if they have to download a map file that is 400mb large because the mapper thought it was cool to add 40 uncompressed songs to the map.
It is not necessary to modify the menu file at all, it will load the song names dynamically. You are done after modifying the script file.
It is also possible to have the Jukebox start with a limited amount of songs, and then by calling the add_song() function at any time during gameplay you could add a song to the menu, since it is dynamic. For instance, you could create an objective system for finding CD's scattered around the map - each CD unlocks a new song in the Jukebox! It's up to you to code these events, obviously. Here is an example function call: