• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

MSFS The 'How-To' Basics of adding custom sounds to an existing Sound.XML stock Asobo file system

Messages
10,129
Country
us-arizona
I am starting this post as a 'learning' tutorial to point people as to how to enter custom sounds to their planes using the Wwise Asobo Sound.xml without burning a new PCK sound bank.

You can add your own sounds (not many) to your aircraft package via making line scripts in the SimVar section with the setting WwiseData="false" (not "true" ) This will signify your sounds are outside of the PCK Sound Bank.

You are allowed 12 of these sections;
custom_sound_ N N is a value between 01 and 12,
eg: custom_engine_sound_ 02
custom_rain_sound_ 07
custom_warning_cockpit_sound_ 11
etc...
I do not know if its 12 total, or 12 of each of these sections. But this will allow you to have 12 (at least) sounds to add to your plane using an existing stock Asobo PCK pack.

* Tip... Did you know you can have your own FSX/P3D style sound pack 'and' a Sound.XML PCK pack running side by side in your plane? Yes... You can set the engine sounds in the Sound XML to have none, use the engine sounds in your plane's own 'Sound.cfg' and with the Wwise system, most of your switches and controls 'should' have sounds now 'if' you used Asobo proper names for Node-ID's, Animation names, etc. You can change the name entries in your own model.XML adding various sounds to your switches, sliding vent knobs, etc, via adding these with various names from the bottom Sound.XML section to your Model.XML Templates.
<WWISE_EVENT_1>battery_switch_on</WWISE_EVENT_1>
<WWISE_EVENT_2>battery_switch_off</WWISE_EVENT_2>

I hope to be adding more to this as I learn more. Right now, I am hung up on trying to get my doors to have a double opening/closing sound. Apparently we can only run 'one' custom sound per Local Var (LVar, command code line) so we have to code up a double set of Local Vars to run both of the opening and closing door sounds, and you are limited in number on those (12), read above.
 
This is a good topic because the sound system in MSFS seems complicated. I'll contribute the little progress I have discovered.

You can certainly add .wav sounds in a sounds.xml file that is for an already built pck file. Just comment out the sections you want to override. You can also use a pck sound pack along with a legacy sound.cfg with associated wave files. The SDK docs lists out which events can be used with legacy sounds in the XML.

Here is an example of an engine sound added to one of the Asobo sound.xml files that uses a default aircraft PCK file. I override the combustion event with my wav files. I'm only using two of the engine sound files because I'm lazy. You need to blend the volume between the RPM values, fading one out while the other gets louder.

As the rest of the xml describes all the other incidental sounds, you get all of that for free.

XML:
<!-- P&W RADIAL -->
    <Sound WwiseEvent="Combustion"  EngineIndex="1"  Wwisedata="false" FileName="xdeBev_RPMr01.wav" FullScaleDistance="0" ViewPoint="All">
        <VolumeCurve SimVar="GENERAL ENG RPM" Units="RPM" Index="1">
          <Point SimValue="0" Output="0" />
          <Point SimValue="600" Output="50" />
          <Point SimValue="800" Output="20" />
          <Point SimValue="1000" Output="0" />         
        </VolumeCurve>
        <PitchCurve SimVar="GENERAL ENG RPM" Units="RPM" Index="1">
          <Point SimValue="600" Output="0.5" />
          <Point SimValue="1000" Output="1.5" />
        </PitchCurve>
    </Sound>

    <Sound WwiseEvent="Combustion"  EngineIndex="1"  Wwisedata="false" FileName="xdeBev_RPMr02.wav" FullScaleDistance="0" ViewPoint="All">
        <VolumeCurve SimVar="GENERAL ENG RPM" Units="PERCENT" Index="1">
          <Point SimValue="600" Output="0" />
          <Point SimValue="800" Output="10" />
          <Point SimValue="1000" Output="50" />
          <Point SimValue="2000" Output="75" />
        </VolumeCurve>
        <PitchCurve SimVar="GENERAL ENG RPM" Units="RPM" Index="1">
          <Point SimValue="800" Output="0.3" />
          <Point SimValue="2500" Output="1" />
        </PitchCurve>
    </Sound>
 
Nice... I didnt know you could add your own engine sounds into the Sound.xml.
When I get a chance, I am looking forward to checking out that sound adjustment system they have. It looks like a modern Flight Sim Sound Studio. (FSSS).
 
I got some help from JonX at GotFriends Studio on how to do door sounds. Its a very tricky thing to do, doing two sounds on one Local Var. Here is how mine is working, with two doors. I struggled with this for over a week and finally got it going. Thanks to JonX and RonH for their help on it. The trick is, to make a LVar system that turns on two separate new LVars and those are linked into your Sound.XML where it will have the sounds linked to those new custom LVars.

This is the Model Interior XML:

<Component ID="ANIMATION_DOOR_LEFT" Node="DoorL_handle_Internal"> <UseTemplate Name="ASOBO_GT_Switch_Code"> <PART_ID>DoorL_handle_Internal</PART_ID> <ANIM_NAME>doorl</ANIM_NAME> <ANIM_CODE>(A:LIGHT PEDESTRAL, bool) 1 == if{ 100 } els{ 0 }</ANIM_CODE> <ANIMTIP_0>DOOR (CLOSED)</ANIMTIP_0> <ANIMTIP_1>DOOR (OPEN)</ANIMTIP_1> <ANIM_LAG>26</ANIM_LAG> <LEFT_SINGLE_CODE> (A:LIGHT PEDESTRAL, bool) 1 == if{ 0 (&gt;A:LIGHT PEDESTRAL, bool) } els{ 1 (&gt;A:LIGHT PEDESTRAL, bool) } </LEFT_SINGLE_CODE> </UseTemplate> </Component> <Component ID="LEFT_DOOR_ANIMATION_SPEED_CHECK" Node="DoorL_handle_Internal"> <UseTemplate Name="ASOBO_GT_Update"> <FREQUENCY>30</FREQUENCY> <UPDATE_CODE> (A:TOTAL WORLD VELOCITY, meters per second) 10.28 &gt; (A:LIGHT PEDESTRAL, bool) 0 &gt; and if{ 0 (&gt;K:PEDESTRAL_LIGHTS_SET) } </UPDATE_CODE> </UseTemplate> </Component> <Component ID="DOOR_LEFT_SOUND_CHECK"> <UseTemplate Name="ASOBO_GT_Update"> <FREQUENCY>30</FREQUENCY> <UPDATE_CODE> (A:LIGHT PEDESTRAL, percent) 5 &gt; if{ (L:DOOR_LEFT_PERCENT_SOUND) 5 &lt;= if{ (L:DOOR_LEFT_OPEN) ! (&gt;L:DOOR_LEFT_OPEN) } } els{ (L:DOOR_LEFT_PERCENT_SOUND) 5 &gt; if{ (L:DOOR_LEFT_CLOSE) ! (&gt;L:DOOR_LEFT_CLOSE) } } (A:LIGHT PEDESTRAL, percent) (&gt;L:DOOR_LEFT_PERCENT_SOUND) </UPDATE_CODE> </UseTemplate> </Component>
The above is the Left Door; Its animation and coding. 3 sections to that. 3 Component sections. No behaviors as you are using stock Asobo GT coding.

Next, you have the entry's in the SoundXML:

<Sound WwiseData="false" WwiseEvent="custom_sound_03" FileName="door_closing_rh" ViewPoint="Inside" NodeName="Door_Inner_RH" LocalVar="DOOR_RIGHT_Close" Continuous="false" BreakOnStop="true"/> <Sound WwiseData="false" WwiseEvent="custom_sound_04" FileName="door_opening_rh" ViewPoint="Inside" NodeName="Door_Inner_RH" LocalVar="DOOR_RIGHT_OPEN" Continuous="false" BreakOnStop="true"/> <Sound WwiseData="false" WwiseEvent="custom_sound_05" FileName="door_closing_lh" ViewPoint="Inside" NodeName="Door_Inner_LH" LocalVar="DOOR_LEFT_Close" Continuous="false" BreakOnStop="true"/> <Sound WwiseData="false" WwiseEvent="custom_sound_06" FileName="door_opening_lh" ViewPoint="Inside" NodeName="Door_Inner_LH" LocalVar="DOOR_LEFT_OPEN" Continuous="false" BreakOnStop="true"/>

On the above code, note both LH and RH Doors, 2 per door, one is the opening sound and the second is the closing sound. I did full sounds that run during the duration of the animation as I couldnt get the 'Range' system to work.

Note the LVars in the SoundXML entries. These are not for the door animation, but the custom new LVars, which act like triggers. This is used because you cannot run 2 sounds on one LVar, so you create 2 LVars for two sounds that run off the Door LVar.

Here is the right door, which uses Strobe lights;

<Component ID="ANIMATION_DOOR_RIGHT" Node="DoorR_handle_Internal"> <UseTemplate Name="ASOBO_GT_Switch_Code"> <PART_ID>DoorR_handle_Internal</PART_ID> <ANIM_NAME>doorr</ANIM_NAME> <ANIM_CODE>(A:LIGHT STROBE, bool) 1 == if{ 100 } els{ 0 }</ANIM_CODE> <ANIMTIP_0>DOOR (CLOSED)</ANIMTIP_0> <ANIMTIP_1>DOOR (OPEN)</ANIMTIP_1> <ANIM_LAG>26</ANIM_LAG> <LEFT_SINGLE_CODE> (A:LIGHT STROBE, bool) 1 == if{ 0 (&gt;A:LIGHT STROBE, bool) } els{ 1 (&gt;A:LIGHT STROBE, bool) } </LEFT_SINGLE_CODE> </UseTemplate> </Component> <Component ID="RIGHT_DOOR_ANIMATION_SPEED_CHECK" Node="DoorR_handle_Internal"> <UseTemplate Name="ASOBO_GT_Update"> <FREQUENCY>30</FREQUENCY> <UPDATE_CODE> (A:TOTAL WORLD VELOCITY, meters per second) 10.28 &gt; (A:LIGHT STROBE, bool) 0 &gt; and if{ 0 (&gt;K:STROBES_SET) } </UPDATE_CODE> </UseTemplate> </Component> <Component ID="DOOR_RIGHT_SOUND_CHECK"> <UseTemplate Name="ASOBO_GT_Update"> <FREQUENCY>30</FREQUENCY> <UPDATE_CODE> (A:LIGHT STROBE, percent) 5 &gt; if{ (L:DOOR_RIGHT_PERCENT_SOUND) 5 &lt;= if{ (L:DOOR_RIGHT_OPEN) ! (&gt;L:DOOR_RIGHT_OPEN) } } els{ (L:DOOR_RIGHT_PERCENT_SOUND) 5 &gt; if{ (L:DOOR_RIGHT_CLOSE) ! (&gt;L:DOOR_RIGHT_CLOSE) } } (A:LIGHT STROBE, percent) (&gt;L:DOOR_RIGHT_PERCENT_SOUND) </UPDATE_CODE> </UseTemplate> </Component>

Now, if you use the L key in FS to turn on your lights (all lights command), your doors open. This version of code, using lights, enables you to have door animations in 'Multi-Player'. JonX says you can use LVars instead, and I hope to check out that route when I get a chance.

So there you go. 2 Sounds per one animation, this is how that is done. Thanks JonX and RonH for your help on this.
 
Back
Top