• 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.

I realized that if you only use a LocalVar to call a click sound, it no longer works for the other switches.
Indeed, the switch actuated first sets the variable to ON and it remains there as long as the switch is not actuated in the other direction.
What makes that the interacted then with the same variable considers that it is already on ON and does not call any sound.
In order for this not to happen, the Lvar must be independent of the value of the simvar/lvar of the switch, you just have to code that the Lvar that calls the sound takes value for a few moments and then returns to an initial value regardless of whether the simvar/lvar of the switch remains modified.
It's all a matter of coding.

Anyway, for the 4-position fuel selector, I got around the problem by setting the variable to ON for positions 0 and 2 and to OFF for positions 1 and 3.
And then we get the ON-OFF-ON-OFF sequence.
The same for this situation, if the Lvar that calls the sound is independent, you must change its value for each change of ON-OFF-ON-OFF.

I use only 1 LVAR to call all the sounds, as you will have seen in my XML code, example: if a switch is activated, its value changes from 0 to 1, my code reads that change, and changes the value of the AIC_SACTION to the value of the sound I want to hear, after a few seconds, I return AIC_SACTION to its initial value, and I can call other sounds, even though the switch at the beginning of the example hasn't changed.
 
OK, that's what I wanted to do, but couldn't figure out how to reset the AIC_ACTION to its initial value after a few seconds.
I didn't see anything like that in the code you provided.
I'll look.

However, in the context of a rotary knob, the delay should be very short to reset the Simvar/LVar.

Thank you for your response and your help.
 
I don't think it's possible to code that logic in the sound XML file, in any case you might be able to do it in the behavior XML.
In my case I do it from a WASM module, this is compiled code that the simulator executes, a WASM module is more complex to do and requires knowledge of software development.
 
Hi,
Unfortunately, I have no knowledge of WASM module programming.
I will ignore these repetitive sounds.
Thank you again for your explanations and your availability.
Regards
 
Hello experts,
I use JS and not WASM, and I am playing sounds using the playInstrumentSound function, it works perfectly as long as the sounds are in the <Avionics> section, perfect.
Now the problem I have is when using sounds defined as wave files. For example this "don't sink" aural warning will not play, while all the other sounds defined with WwiseData="true" work perfectly.

Code:
  <AvionicSounds>
    <Sound WwiseData="true" WwiseEvent="aural_10ft" NodeName="Compass_cylinder"/>
    <Sound WwiseData="true" WwiseEvent="aural_20ft" NodeName="Compass_cylinder"/>
    <Sound WwiseData="true" WwiseEvent="aural_30ft" NodeName="Compass_cylinder"/>
     [...]
    <!-- Attempt to use sound from wav file for avionics -->
    <Sound WwiseData="false" WwiseEvent="dont_sink" FileName="Audio-DontSink" NodeName="Compass_cylinder"/>   
</AvionicSounds>

I confirm I placed the Audio-DontSink.wav file in the sound folder, I confirm it is referenced in the layout.json as expected and I confirm it is 16 bits PCM.
So what is wrong?

If you have an idea, please let me know :)

Thanks,
Eric
 
I finally found the explanation, it was a problem in the aircraft interior model file. A small inconsistency in the XML and it ruins all the rest... Now fixed, fortunately.
 
Hi

Wonder if anyone can help, I am trying to replace a default HiLoChime sound with a .wav file rather than the file in .pck. However the sound does not work when the button is pressed in the cockpit.

The sound.xml has the following line:
<Sound WwiseData="false" WwiseEvent="HiLoChime" FileName="HiLoChime" ViewPoint="Inside" BreakOnStop="true" ChangedOnly="true" LocalVar="HiLoChime"> </Sound>

In my sound folder I have the following file:
HiLoChime.wav (PCM format)

In the layout.json the line has been automatically added.

Any help would be appreciated.

Jordan
 
Looks like your Sound definition line es not complete/correct.

Check this one that is working for me.

<Sound WwiseData="false" WwiseEvent="custom_sound_01" FileName="sound_001" ViewPoint="Inside" Continuous="false" LocalVar="AIC_SACTION" Units="number" Panning="-9000"><Requires LocalVar="AIC_SACTION" Units="number"><Range LowerBound="1" UpperBound="1"/></Requires></Sound>
 
Looks like your Sound definition line es not complete/correct.

Check this one that is working for me.

<Sound WwiseData="false" WwiseEvent="custom_sound_01" FileName="sound_001" ViewPoint="Inside" Continuous="false" LocalVar="AIC_SACTION" Units="number" Panning="-9000"><Requires LocalVar="AIC_SACTION" Units="number"><Range LowerBound="1" UpperBound="1"/></Requires></Sound>
Sadly this has not worked.

1. Do I need to change the WwiseEvent to custom_sound_x?
2. In the aircraft xml file I have the following line for anim name (L:Switch_102_x, number). Should I change LocalVar to this?

The sound.xml now has the following line:
<Sound WwiseData="false" WwiseEvent="HiLoChime" FileName="HiLoChime" ViewPoint="Inside" Continuous="false" LocalVar="HiLoChime" Units="number" Panning="-9000"><Requires LocalVar="HiLoChime" Units="number"><Range LowerBound="1" UpperBound="1"/>
 
Do I need to change the WwiseEvent to custom_sound_x?
as far as I understand yes, according to the wwise events table:

In the aircraft xml file I have the following line for anim name (L:Switch_102_x, number). Should I change LocalVar to this?
It depends on when you want the sound to be triggered, if it is according to the value of that lvar, you should use that one.
The lvar to trigger the sound must exist and should take the value of what is defined in "Range"
 
@jordanf93

Warning, this is theory, I've never tried it:

You should, first, comment/delete the line that call the current sound from the wwise package in the Sound.xml file, I think it is this one:
"<Sound WwiseData="true" WwiseEvent="HiLoChime" ViewPoint="Inside" BreakOnStop="true" ChangedOnly="true" LocalVar="HiLoChime"> </Sound>"

Then, try one of these options:

Add:
<Sound WwiseData="false" WwiseEvent="custom_sound_01" FileName="your_wav_file_name" ViewPoint="Inside" Continuous="false" LocalVar="HiLoChime" Units="number"><Requires LocalVar="HiLoChime" Units="number">
<Range LowerBound="1" UpperBound="2"/></Requires></Sound>

(note the Bounds definition 1 & 2, Idk if this could work.)

OR

Add:
<Sound WwiseData="false" WwiseEvent="custom_sound_01" FileName="your_wav_file_name" ViewPoint="Inside" Continuous="false" LocalVar="HiLoChime" Units="number"><Requires LocalVar="HiLoChime" Units="number">
<Range LowerBound="1" UpperBound="1"/></Requires></Sound>
<Sound WwiseData="false" WwiseEvent="custom_sound_02" FileName="your_wav_file_name" ViewPoint="Inside" Continuous="false" LocalVar="HiLoChime" Units="number"><Requires LocalVar="HiLoChime" Units="number">
<Range LowerBound="2" UpperBound="2"/></Requires></Sound>

(This method seems less efficient, but it has a better chance of working.)

why those options?
From what I have verified, in the PMDG, there is the Lvar "HiLoChime", and its value changes alternately between "1" and "2" every time that should play the sound (like pressing "ATTEND"), so, if it value is "1" and you press ATTEND, its value changes to "2", then if you press ATTEND again, its value returns to "1", and so...


Regards.
 
@jordanf93

Warning, this is theory, I've never tried it:

You should, first, comment/delete the line that call the current sound from the wwise package in the Sound.xml file, I think it is this one:
"<Sound WwiseData="true" WwiseEvent="HiLoChime" ViewPoint="Inside" BreakOnStop="true" ChangedOnly="true" LocalVar="HiLoChime"> </Sound>"

Then, try one of these options:

Add:
<Sound WwiseData="false" WwiseEvent="custom_sound_01" FileName="your_wav_file_name" ViewPoint="Inside" Continuous="false" LocalVar="HiLoChime" Units="number"><Requires LocalVar="HiLoChime" Units="number">
<Range LowerBound="1" UpperBound="2"/></Requires></Sound>

(note the Bounds definition 1 & 2, Idk if this could work.)

OR

Add:
<Sound WwiseData="false" WwiseEvent="custom_sound_01" FileName="your_wav_file_name" ViewPoint="Inside" Continuous="false" LocalVar="HiLoChime" Units="number"><Requires LocalVar="HiLoChime" Units="number">
<Range LowerBound="1" UpperBound="1"/></Requires></Sound>
<Sound WwiseData="false" WwiseEvent="custom_sound_02" FileName="your_wav_file_name" ViewPoint="Inside" Continuous="false" LocalVar="HiLoChime" Units="number"><Requires LocalVar="HiLoChime" Units="number">
<Range LowerBound="2" UpperBound="2"/></Requires></Sound>

(This method seems less efficient, but it has a better chance of working.)

why those options?
From what I have verified, in the PMDG, there is the Lvar "HiLoChime", and its value changes alternately between "1" and "2" every time that should play the sound (like pressing "ATTEND"), so, if it value is "1" and you press ATTEND, its value changes to "2", then if you press ATTEND again, its value returns to "1", and so...


Regards.
This has not worked although I may be doing something wrong.
If I did use the sounds that were already in the default PCK file of the PMDG. What would I add to the xml to increase the volume of say the HiLoChime?
 
What would I add to the xml to increase the volume of say the HiLoChime?
Unfortunately it seems like you can't edit the volume of individual sounds in a Wwise sound package with the sound.xml. There is simply no parameter defined in the sound.xml that let's you individual sound levels (although I think you can if you use the old .wav file code). This is possibly a limitation of Wwise with the expectation that you would balance the sounds before creating the PCK.
 
It seems that @conradf104 found a way (on the old wav code), although it is not clear to me how to apply it.

 
@jordanf93

Warning, this is theory, I've never tried it:

You should, first, comment/delete the line that call the current sound from the wwise package in the Sound.xml file, I think it is this one:
"<Sound WwiseData="true" WwiseEvent="HiLoChime" ViewPoint="Inside" BreakOnStop="true" ChangedOnly="true" LocalVar="HiLoChime"> </Sound>"

Then, try one of these options:

Add:
<Sound WwiseData="false" WwiseEvent="custom_sound_01" FileName="your_wav_file_name" ViewPoint="Inside" Continuous="false" LocalVar="HiLoChime" Units="number"><Requires LocalVar="HiLoChime" Units="number">
<Range LowerBound="1" UpperBound="2"/></Requires></Sound>

(note the Bounds definition 1 & 2, Idk if this could work.)

OR

Add:
<Sound WwiseData="false" WwiseEvent="custom_sound_01" FileName="your_wav_file_name" ViewPoint="Inside" Continuous="false" LocalVar="HiLoChime" Units="number"><Requires LocalVar="HiLoChime" Units="number">
<Range LowerBound="1" UpperBound="1"/></Requires></Sound>
<Sound WwiseData="false" WwiseEvent="custom_sound_02" FileName="your_wav_file_name" ViewPoint="Inside" Continuous="false" LocalVar="HiLoChime" Units="number"><Requires LocalVar="HiLoChime" Units="number">
<Range LowerBound="2" UpperBound="2"/></Requires></Sound>

(This method seems less efficient, but it has a better chance of working.)

why those options?
From what I have verified, in the PMDG, there is the Lvar "HiLoChime", and its value changes alternately between "1" and "2" every time that should play the sound (like pressing "ATTEND"), so, if it value is "1" and you press ATTEND, its value changes to "2", then if you press ATTEND again, its value returns to "1", and so...


Regards.
Can confirm that both of these methods work! Thanks alot :)
 
It seems that @conradf104 found a way, although it is not clear to me how to apply it.

I think it may be something that requires to be added to the end of the line in the xml file. Hmmm..
 
Back
Top