Documentation/Engine/Sound/Modding

From SCS Modding Wiki
< Documentation‎ | Engine‎ | Sound
Revision as of 10:09, 5 March 2020 by Lubos.scs (talk | contribs) (Prepare bank to the game - Step by step)

Jump to navigation Jump to search

Modding Sound

FMOD requires each sound bank to have its own globally unique identifier (GUID). It also requires that the main mix buses of the master bank of each sound have the same GUIDs.
FMOD Studio does not provide a user interface to edit GUIDs, so to make it easier to create a correctly authored third party sounds, we are providing our Master Bank as a template for the new sound projects.

All modded sounds must be a part of new FMOD bank to be usable for the game.
Clicking the link below you can download "template.bank" FMOD Studio project.
You need install FMOD Studio software to authoring new sound for the game.

Create own bank - Step by step

  1. Download template.bank project.
  2. Unzip project to the 'your new sound project' folder.
  3. Rename "template.fspro" file (in project root folder) to "[my project name].fspro".
    (Not necessary but recommended.)
  4. Open your project (simply open [my project name].fspro file) in FMOD Studio software.
  5. There are three browsers that can appear in an event editor window: the events browser, the banks browser, and the assets browser.
    To create a new bank, right click in an empty space in the banks browser and select "New Bank".
  6. Set the name of the new bank.
    The bank name determines the name of the bank file so it is strongly recommended to use system independen names (lowercase chars, no spaces,...).
  7. That is it!
    New GUID is automatically create by FMOD for the new bank, so you have own independent bank which can be used in the game for modded sounds.

Notes:
- Always create new bank because creating new GUID for the bank is necessary!
- If you create new project from other templates (for ex. from your older project) also always create new bank. The GUIDs have to be unique!
- Never rename 'master' bank to other bank!
- Never delete the standard buses that come with the template project! If you delete them and create your own, they will not work even if the names are the same!

Create own sound - Step by step

It is very easy if you are familiar with FMOD Studio.

  1. Open your project in FMOD Studio to edit it.
    The events browser displays your project's events and event folders.
  2. To create an event in this browser, right click on an empty space and select "New Event" from the context menu.
    This opens a sub-menu, in which you have the option to make a 3D Event or a 2D Event (or a custom default event).
  3. Select 2D or 3D option in dependency which sound you want to modding.
  4. Set name for the new event. (System independent names are strongly recommended.)
  5. Assign the event to your bank.
    Right click on the "new event", select "Assign to Bank" menu and select target bank in submenu.
  6. Assign the event to the audio bus.
    Open window "Mixer Routing" and drag the "new event" to the target audio bus.
  7. Edit your sound...

Notes:
- Always create new events!
- If you create new project from other templates (for ex. from your older project) also always create new event with unique GUID!
- The 'copy-paste' process create new GUID for the event so it is recomended way to duplicate or move sound events.
- Take a care for abilities of sound - 2D/3D, loop, controlling parameters. Sound features are dependent on sound type you modding. Some abilities of the sound are necessary for the correct sound playing.

Prepare bank to the game - Step by step

When you finished work on new sounds you should prepare the sound bank to the game.

  1. Build the bank.
    Simply select menu File / Build... in the FMOD Studio.
    The file "[bank name].bank" should be created in the "build" subfolder of your project.
    The "master.bank" and "master.strings.bank" files will probably also be created, but ignore them.
  2. Export GUIDs.
    Select menu File / Export GUIDs... in the FMOD Studio.
    The file "GUIDs.txt" should be created in the same subfolder.
    (You should see your new events in the object list in the GUIDs.txt file content.)
  3. Rename file "GUIDs.txt" to "[bank name].bank.guids".
  4. You can optimize the contents of the guids file by leaving only those objects you created yourself and remain part of the new bank. But it is not absolutely necessary.