Sound Editing

 

Introduction to Sound Editing

Path: Fleet Operations\Data\Sounds

In Fleet Operations many sound effects are in .wav format, but since the game uses the FMOD Ex sound engine, OGG and MP3 file formats are also supported if desired. The types of sounds in the game include voice-over / unit speech, weapons and other sound effects, and of course the music files. The music is not included in the standard install for hosting limits, as well as problems with installation sizes. The multimedia pack is instead available via another download.

All sound files in Fleet Ops are editable without compromising multiplayer compatibility.

This is one of the very few features in Fleet Ops where this is possible. This means that you can change and replace any of the sound effects that you wish, so long as the edited file has the correct name. If it does not have the correct name, the game will not recognize the file and therefore will not play the sound in-game. You may still delete a sound without losing compatibility, as it will have the same effect as having it improperly named. If you delete a Fleet Ops sound file, make sure the appropriate reference in the events.dat file is deleted as well or you will cause a crash.

Although it may seem difficult to edit sound files, there is a free tool called Audacity that will allow you to import almost any sound file, edit it, and export it in nearly any format. The process of editing sound files, much like editing textures or bitmaps, is really up to you. However, this tool is quite easy to use and should make the process simpler. For instructions on how to use it, visit the Audacity site or its support forums.

To reiterate, if you want to edit the sounds that are played in-game and still enjoy multiplayer games, then you should have no problem doing so. If you do not care about compatibility, then you might want to take a look at the events.dat file in the main directory, in which you can replace and change certain sounds more easily. If you are not sure, then just stick with editing the actual sounds as there are few, if any, ways to mess that up.

Sound Format Recommendations

Fleet Operations' sound engine supports various formats. The most important ones are .wav, .ogg and .mp3 . Remember to change the audio.odf configuration file to match the sound format, otherwise you may end up with distorted effects.

WAV

Wave is a lossless audio format. It was the only format supported in Stock Armada II. The advantage of the format is its CPU friendliness. That means there is processing to be done by the CPU for this audio format to be played. The disadvantage is the big file size of the format, as it is uncompressed. Wav is the recommended format to be used for audio effects like weapons fire, as these are played often and sometimes even a dozen times simultanously in a battle. Short audio effects don't take too much space on the HDD.

MP3

MP3 is a compressed (lossy) sound format. Compared to WAV it features a much smaller file size. This format is not recommended to be used for sound effects. Due to technical limitations, MP3s have a few miliseconds of silence (called gap) at the beginning of the sound which makes it especially unsuitable for looping sounds or sounds that are meant to be matched to visual effects (like explosions). Use for sound effects therefore is not recommended. Best usage scenarios for this format within Armada are either voice or music.

OGG

OGG is similar to MP3, but is said to have a generally better audio quality at the same or even smaller file size. OGG also doesn't have the gap problem the MP3 format has. Therefore it can be used for sound effects. Recommended use of OGG is either voice, music or rarely played sound effects.

Directories

Sound files can be stored in the following directories relative to the Fleet Operations Data\ directory or from the root of a Modification Module:

sounds\effects
sounds\music
sounds\voiceover\cineractive
sounds\voiceover\ingame

It does not matter in which of these directories the sound files are stored, all that is important is their filename. Be careful not to use the same filename twice in different directories, otherwise only one of the files you created will be used.

The Events.dat File

Path: Fleet Operations\Data\events.dat

This file controls most of the sound aspects of the game outside of weapons and music. Things such as the voices that play when you click on units, the disembodied computer voice, text that appears on the screen, and other things like minimap pings are all controlled via the events.dat file. The best way to edit this file is with Notepad++, because regular Notepad cannot save certain Fleet Ops related characters (Wordpad and regular Notepad work if you are just editing the stock Armada II version of the file).

Each time the word “event” is mentioned in an ODF, it is defining a location in the events.dat file. Remember to include the correct extension in the event name, otherwise the sound will not play.

These locations are defined by the event name, followed by {}. The event coding lies within the {}, as the following example will demonstrate:

InsufficientMetal{

}

Consequently, this example shows that the event for running out of metal has no sound played and no text shown on screen.

Making Text Appear

When you want to make text appear on the screen when triggering an event, the correct format is {Text "text you want on screen"}.

VTuneOff{
Text "VTune sampling turned off"
}

In this example, the text, "VTune sampling turned off", will be displayed when the event, VTuneOff, is played.

When defining text in the events.dat file, it is possible to cause Fleet Ops to look for the text to display in the dynamic_localized_strings.h file. To do this, make sure that the string matches the string in the dynamic_localized_strings.h file and has not been already used. For example:

EventName{
Text "GAME-RESOURCES-INSUFFICIENT_TRITANIUM"
}

This will thus make the game look for the string "GAME-RESOURCES-INSUFFICIENT_TRITANIUM" in the dynamic_localized_strings.h file. Consequently when this event is called, the text defined by this string - "You do not have enough tritanium to perform that task" - will appear on screen. Information on editing the dynamic_localized_strings.h file can be found in Editing Tooltips.

Playing a Sound

When you want the event to play a sound, you will need to tell the file to expect a set of sounds for the specific event. To do this, add the word "Table" before the sound entries.

The format, {sound <faction name> "sound file.wav"}, is used for each entry in the sound table. Note that the faction that hears the sound is specified within the <>. Consequently, if a unit is captured, another sound needs to be specified (if you want to hear something after capture).

DilithiumTransferred{
Table
            Sound <borg> "borgadv_resources_transfered.wav"
            Sound <romulanempire> "romulanadv_dilithium_transfered.wav"
            Sound <unitedfederation> "federationadv_dilithium_transfered.wav"
            Sound <klingonempire> "klingonadv_resources_transfered.wav"
            Sound <dominion> "dominionadv_resources_transfered.wav"
}

In this example there is a sound table for the event of transferring dilithium. It can be seen here that each faction has its own sound value.

The text code may work with the race name, but this has not been tested yet.

Placing New Sound Tables

Note that the location that new sound tables are put in the events.dat file is important, and it is best to put them after the final voiceovers for Fleet Ops units. The final Fleet Ops sound is the selection for the the Dominion Hyperspace Sensor Station, and it should look like this:

DominionSupersensorSelect{
Table
            Sound "dominion_supersensor.wav"
Voice 0
}

Sounds for Specific Unit Commands

If you want to add sounds to a unit, you'll need to go to that unit's ODF and look for the commands starting with Event. Some examples are:

eventselect = "" // This triggers the sounds in the table to play when you select a unit

eventacknowledge = "" // This triggers the sounds in the table to play when you give a ship special orders

eventattack = "" // This triggers the sounds in the table to play when you order a unit to attack

eventstop = "" // This triggers the sounds in the table to play when you order the ship to stop

eventmove = "" // This triggers the sounds in the table to play when you order a ship to move to a location

eventrepair = "" // This triggers the sounds in the table to play when you order a ship to repair

Note that many sounds are not relayed by ODF commands, but are solely defined by the events.dat file .

Multiple Sound Entries

When working with the sound entries (and the text entries, if they work with the faction name), you can have multiple entries. This will randomize what values the game uses. For example:

Basic1DestroyerStop{
Table
            Sound <borg> "borg_unit_stop1.wav"
            Sound <borg> "borg_unit_stop2.wav"
            Sound <borg> "borg_unit_stop3.wav"
            Sound <borg> "borg_unit_stop4.wav"
            Sound <borg> "borg_unit_stop5.wav"
            Sound <dominion> "dominion_destroyer1_stop.wav"
            Sound <unitedfederation> "federation_destroyer1_stop.wav"
            Sound <klingonempire> "klingon_destroyer1_stop.wav"
            Sound <romulanempire> "romulan_destroyer1_stop.wav"
}

Consequently, when ordered to stop, the Borg Destroyer will choose one of the five different sound entries specified in the table.

Minimap Pings

To add a ping to the minimap (such as indicating when you have been attacked) you can add an additional line under the "Table" entry:  Marker radius X shrink Y time Z color R G B .

The Marker Radius is the maximum size of the ping, the Marker Shrink is the minimum size of the ping, the Marker Time is the length of time in seconds it takes to go from maximum to minimum size, and the Marker Color is determined in Red Green Blue (RGB) values (measured in percent, where 1 is 100%).

BaseUnderAttack{
Table
            Sound <borg> "borgadv_under_attack.wav"
            Sound <romulanempire> "romulanadv_under_attack.wav"
Marker radius 128 shrink 0.025 time 4 color 1 0 0
Text "EVENTS_BASE_UNDER_ATTACK"
}

In this example, the event activates a red ping and displays the text associated with "EVENTS_BASE_UNDER_ATTACK".

TriggerInterval

TriggerInterval is the command needed to indicate how long before the event is replayed (the value is roughly measured in seconds).

BaseUnderAttack{
Table
            Sound <borg> "borgadv_under_attack.wav"
            Sound <romulanempire> "romulanadv_under_attack.wav"
Text "EVENTS_BASE_UNDER_ATTACK"
TriggerInterval 30
}

In this example, the event is replayed a maximum of once every 30 seconds (if triggered repeatedly) and displays the text associated with "EVENTS_BASE_UNDER_ATTACK".

SoundPriority 2

If you want a specific sound to override any other sound that is to be played with concurrent events, use the command SoundPriority 2. This just tells the game that this event is most important.

BaseUnderAttack{
Table
            Sound <borg> "borgadv_under_attack.wav"
            Sound <romulanempire> "romulanadv_under_attack.wav"
SoundPriority 2
Text "EVENTS_BASE_UNDER_ATTACK"
}

In this example, the event takes priority over other events, as it is defined as being the most important. It displays the text associated with "EVENTS_BASE_UNDER_ATTACK".

SaveLocation

SaveLocation is required for recording any event (like pings) in the Timeline and Battles tabs of the Admiral's Log. It also helps when trying to see where the event started, even if it has ended or moved.

It also enables the zoom to location feature when the space bar is pressed after the event has triggered. Note that a maximum of three events may be saved at any one time in this manner.

BaseUnderAttack{
Table
            Sound <borg> "borgadv_under_attack.wav"
            Sound <romulanempire> "romulanadv_under_attack.wav"
            SaveLocation
Text "EVENTS_BASE_UNDER_ATTACK"
}

When the event occurs it will be recorded in the Admiral's Log and it will display the text associated with "EVENTS_BASE_UNDER_ATTACK".

Voice #

Voice # is used for the sound channels, fixing the sound channel to a specific slot number (i.e. 0,1,2,3 etc). Consequently, if you select multiple units that are all referenced as Voice 0, you will only hear the sound of the first selected unit (until that unit's event has ended).

DominionSupersensorSelect{
Table
            Sound "dominion_supersensor.wav"
Voice 0
}

In old Fleet Operations versions, Voice 0 is used for all structures, so all structures use slot 0 and you will only hear the sound event of the first structure you select. Since there are a limited number of sound channels, if you have a lot of weapons fire, firing sounds can be lost. Thus Voice # can be used to ensure that different types of sounds get access to a sound channel so that you can hear the event in question. Note that with the inclusion of the FMOD Ex sound engine, it is highly unlikely that you will override the number of possible sound channels.

Global

Global is used to make normal events referenced by the Ordnance shotInfo command and Weapon fireEventID command visible to the player. *test if events become visible to all allied players*

Global is used to make certain special events visible to all players, allied or enemy. If the Global command is not included, the event will only display for the player who triggered the event. This works with superweapon and CTF (capture the flag) hardcoded event labels: for instance MassTranswarpWarning, TemporalDisplacementWarning, BlackHoleCreatorWarning, SubspaceRippleWarning and CTFLocalDropped, CTFLocalTaken, CTFLocalReturned, CTFLocalCaptured *and possibly others, including EnteringDangerousNebula.

TemporalDisplacementWarning{
Text "Awesome Device Launched"
Global
Marker radius 32 shrink 0.05 time 1 color 0 1 0
}

In this example, when the event occurs, the minimap will be pinged for all players and the text will display for all players.

Hardcoded Event Labels

Note that if a specific event label isn't present, yet an ODF calls for the event, it will use one of the already existing events.

Event Label When The Label Is Used
ShipConstructionBegin Shipyard, Starbase or BuildYard begins to construct a GameObject
ShipConstructionComplete Shipyard, Starbase or BuildYard finishes constructing a GameObject
FacilityConstructionBegin ConstructionRig begins to construct a GameObject
FacilityConstructionComplete ConstructionRig finishes constructing a GameObject
ResearchBegin ResearchStation begins to construct a GameObject
ResearchComplete ResearchStation finishes constructing a GameObject
ConstructionCancelled All Producers current construction is cancelled
ResearchCancelled ResearchStation current construction is cancelled. Overwrites ConstructionCancelled
BaseUnderAttack GameObject is attacked when Craft ODF command is_starbase = 1
InsufficientDilithium Not enough dilithium to begin GameObject construction
InsufficientCrew Not enough crew to begin GameObject construction
InsufficientFedOfficers Non-functional
InsufficientBorgOfficers Non-functional
InsufficientRomOfficers Non-functional
InsufficientKlingOfficers Non-functional
InsufficientCardOfficers Non-functional
InsufficientSpeciesOfficers Non-functional
InsufficientSpace non functional???
CantBuildThere ConstructionRig chooses a location to build a GameObject and the location is invalid (or becomes invalid)
ShipDecommission GameObject is decommissioned when Craft ODF command is_starbase = 0
StationDecommission GameObject is decommissioned when Craft ODF command is_starbase = 1
MoonDepleted A Scrap's resources are drained to zero or trickleAmount
LatinumNebulaDepleted A LatinumNebula's resources are drained to zero or trickleAmount
PlanetDepleted A Planet's resources are drained to zero or trickleAmount
ComputerRedAlert A GameObject clicks Red Alert status. Overwritten by Craft eventRedAlert ODF command
ComputerYellowAlert A GameObject clicks Yellow Alert status. Overwritten by Craft eventYellowAlert ODF command
ComputerGreenAlert A GameObject clicks Green Alert status. Overwritten by Craft eventGreenAlert ODF command
InsufficientSpecialEnergy non functional, or overwritten???
MetalTransferred Player transfers metal using the Communications Menu
LatinumTransferred Player transfers latinum using the Communications Menu
BiomatterTransferred Player transfers biomatter using the Communications Menu
CrewTransferred Player transfers crew using the Communications Menu
DilithiumTransferred Player transfers dilithium using the Communications Menu
UnitsTransferred Player transfers GameObjects using the Communications Menu
EnemyDetected Non-functional???
EnemyEngaged GameObject is attacked by or attacks another GameObject. Disabled when the Weapon ODF command beneficial = 1
InvalidAction GameObject is given any order which it cannot accomplish
SelfDestructBegun SelfDestruct Weapon activated
SelfDestructCancel SelfDestruct Weapon cancelled
UnableToTransport GameObject is given a transport order to an invalid target
ComputerAcknowledge is it used???
StationRecrewing A GameObject uses its Recrew command
CannotRepair A GameObject is given a repair order and no repair facilities are available
MassTranswarpWarning A WormholeGenerator Weapon is used
TemporalDisplacementWarning A TemporalDisplacement Ordnance is used
BlackHoleCreatorWarning A BlackHoleCreator Ordnance is used
SubspaceRippleWarning A RepulsionWave Ordnance is used
FerengiArrives An NPC Scavenger enters the map
PlanetaryShields A Planet finishes construction of PlanetShields
VTuneOn  
VTuneOff  
InsufficientLatinumToBuy Not enough latinum to purchase resources at the TradingStation
InsufficientDilithiumToBuy Not enough dilithium to purchase resources at the TradingStation
InsufficientMetalToBuy Not enough metal to purchase resources at the TradingStation
InsufficientLatinum Not enough latinum to begin GameObject construction
InsufficientMetal Not enough metal to begin GameObject construction
InsufficientBiomatter Not enough biomatter to begin GameObject construction
ColonizeStarted A Colony begins colonization of a Planet
PlanetColonized A Colony finishes colonization of a Planet
ColonyLost The player's Planet is captured by the enemy
PlanetConquered The player captures a Planet (can be enemy or neutral)
PlanetAttack The player's Planet is attacked. If not present, reverts to Insufficient[resource] event.
EnteringDangerousNebula GameObject enters a Nebula that deals damage or kills crew
NebulaDeathImminent GameObject loses more than 30% of its crew or hull hitpoints. Default overwritten by Craft percentNebulaWarn ODF command.
LocalVictorious The player was victorious in normal games
LocalVanquished The player was defeated in normal games
LocalEliminated The player was eliminated in normal team games
OtherEliminated A player from a team was eliminated.
GameTied Both sides have the same score in CTF, Collect Latinum, or Colonize Planets games
CTFLocalTaken The Flag in CTF multiplayer games is taken from the enemy
CTFLocalDropped The Flag in CTF multiplayer games is dropped by the enemy
CTFLocalReturned The Flag in CTF multiplayer games is returned to the player's team
CTFLocalCaptured The Flag in CTF multiplayer games is taken from the player's team
ColonizePlanetsLocalSuccess The player has completed the objectives in multiplayer Colonize Planets games
AssaultLocalDefenderBaseHeld The defending player was victorious
AssaultLocalAttackerBaseHeld The attacking player was defeated
LatinumLocalCollectedEnough The player collects enough latinum in Collect Latinum multiplayer games
LatinumEnemyCollectedEnough The enemy collects enough latinum in Collect Latinum multiplayer games
LatinumCollectionMilestone A player collects enough latinum to achieve a milestone. No text message here, as it is generated by the program to include the player's name and relationship
CeaseFireOneMinuteWarning Cease Fire has 1 minute until end
CeaseFireOver Cease Fire ends
AlliancesChangedNotification Player's allegiance status is changed from the Communications Menu. No text message here, as it is generated by the program to include the player's name and relationship
PlayerDepartureNotification A player leaves the game. No text message here, as it is generated by the program to include the player's name and relationship
ShipUpgradeBegin Construction of Pod with isShipUpgrade = 1 begins
ShipUpgradeComplete Construction of Pod with isShipUpgrade = 1 is finished
ShipUpgradeCancelled Construction of Pod with isShipUpgrade = 1 is cancelled
EvolutionBegin Evolver begins to construct a GameObject
EvolutionComplete Evolver finishes constructing a GameObject
EvolutionCancelled Evolver current construction cancelled. Overwrites ConstructionCancelled
DefendPlanetLocalFailure The player has failed the objectives in multiplayer Defend Planet games
   
InvalidEvent ??? #this event should be the first in this file
#No marker
DefaultMarkerOnly ??? Marker #uses default radius, etc.
emptyevent ???