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

One Shot Sound & Play List

Messages
99
Country
unitedstates
I would like to use the One Shot Sound action, or Play List action, with sounds and music that come with FSX. The only way I have been able to make these work is to copy the file into my mission folder.

Has anyone found a way to reference the sound files in the Sound folder in FSX without making a copy?

Thanks,
Gunner
 
That's a good question. Can't you use relative paths like ".\..\..\sound\ding.wav"? Well, maybe this won't work. But how about placing a shortcut in the mission-sound-folder that's called "gotoding.wav" and calling this from the mission?
 
It worked! When I use this for a file name:

../../../../Sound/UIMusic/FSX01.wav

the FSX01.wav music plays.

I have not had any luck with the Playlist, but it works as a One Shot Sound.

Thanks, and I learned what Absolute and Relative paths are :)

Gunner
 
:)

I have to agree with Kevin, though: The PlayList seems to have a bug. That's bad, for it is definitely a nice idea.
But having the oneshotaction and SFX I think that doesn't matter too much.
 
:)

But having the oneshotaction and SFX I think that doesn't matter too much.

Unless, that is, you want to use the music ... in which case, it severely increases your filesize when distributing the mission - because now the music file has to be copied to yoru Mission/Sound folder. :(
 
Erm, Gunner stated that you could use relative paths. So I think that means you don't have to put them into your own folder - unless you want to use your own music. But in that case you would have to include it into the package anyway. :D
 
I found a way to repeat the music using the One Shot sound. When the One Shot sound is triggered, I started a timer trigger that starts the next music file. This could also be used with different music files. I would be nice if the Play List worked, but I think I found a work around.

Gunner
 
Playlists do work !!! - Working Example

Hi Folks

In case you hadn't seen it -
Paul Lange posted on AVSIM -
"the playlist files need to be in the main sound folder for FSX."

Cheer Paul for that. :D



UPDATE -
Playlists do work !!!



Warning/Caveats -

The soundfile must exist on the specified path.



ENSURE you use an appropriate & unique name for your sound clip,
otherwise you'll possibly overwrite someone else's clip.
i.e.
Don't use song1.wav, song2.wav, etc. ;)

Prefix the clip with your mission name.
e.g.
MyRescueMission_song1.wav, MyRescueMission_song2.wav, etc



Suggest adding a common subfolder,
and that we all adopt that as a common standard.
e.g.
Microsoft Flight Simulator X\Sound\Mission_Playlists

And that you place your soundfiles in mission specific subfolders.
e.g.
Microsoft Flight Simulator X\Sound\Mission_Playlists\MyRescueMission

In six months time, or whenever,
a user may find themselves short on diskspace,
and don't know which files to delete.



Ensure your soundfile is an appropriate format,
(radio quality, as maximum), and of a smallish size.

Nobody wants to download 600MB of your favourite music. :D

You can play a clip indefinitely
by repeating it, using multiple calls in the playlist.

See example clips in Microsoft Flight Simulator X\Sound\UIMusic



Microsoft ADPCM 11.025 kHz, 4 Bit, Mono
is NOT supported,
hence in the example I've posted,
the odd sounding thunder, & speeded up dialog on the second playlist.

PCM 22.050 kHz, 16 Bit, Mono,
and MP3, WMA, are not supported.



Testing your playlists.
If you fire a playlist,
then exit or reload the mission,
before the playlist is completed.
The interupted track & remaining playlist tracks will continue to play !



--------------------------------------------------------------------------
Here's some example code -

It will play two different short playlists,
using sounds & UIMusic which already exist in your FSX.

A 5 second timer activates -
a) the first playlist.
b) a 60 second timer, which then fires the second playlist.

NB
For readability this code is laid out in order of firing,
and will work as is.
If added to a mission, the OPT will re-order it.

On screen notices & timers are included for test purposes.

Code:
        <SimMission.TimerTrigger InstanceId="{A8498446-0335-4E76-BB37-82B9AEAD1A76}">
            <Descr>_Init_TTimer_S5</Descr>
            <StopTime>5.000</StopTime>
            <OnScreenTimer>True</OnScreenTimer>
            <Actions>
                <ObjectReference id="_Triggered_TTimer_S120_AA_On" InstanceId="{35CE0E66-F666-4E9C-8CCD-929C54BCE3C7}">
                </ObjectReference>
                <ObjectReference id="_First_PLAYLIST_DIALOG_AD" InstanceId="{D3BDAB41-B690-499F-B63D-1ECDAB56C1AA}">
                </ObjectReference>
                <ObjectReference id="_First_PLAYLIST_AP" InstanceId="{6DA689F9-67C1-49BD-AD95-3A633E428709}">
                </ObjectReference>
            </Actions>
        </SimMission.TimerTrigger>

        <SimMission.ObjectActivationAction InstanceId="{35CE0E66-F666-4E9C-8CCD-929C54BCE3C7}">
            <Descr>_Triggered_TTimer_S120_AA_On</Descr>
            <ObjectReferenceList>
                <ObjectReference id="_Triggered_TTimer_S60" InstanceId="{860011FB-F217-4FEF-BE94-C33C4F648AE9}">
                </ObjectReference>
            </ObjectReferenceList>
        </SimMission.ObjectActivationAction>

        <SimMission.DialogAction InstanceId="{D3BDAB41-B690-499F-B63D-1ECDAB56C1AA}">
            <Descr>_First_PLAYLIST_DIALOG_AD</Descr>
            <Text>
5 second Timer activated _First_PLAYLIST_AP
</Text>
        </SimMission.DialogAction>

        <SimMission.PlayListAction InstanceId="{6DA689F9-67C1-49BD-AD95-3A633E428709}">
            <Descr>_First_PLAYLIST_AP</Descr>
            <PlayListItem>
                <Descr>PlayListItem 1</Descr>
                <SoundFileName>MRSDAHL.wav</SoundFileName>
                <RandomizeInList>True</RandomizeInList>
            </PlayListItem>
            <PlayListItem>
                <Descr>PlayListItem 2</Descr>
                <SoundFileName>backcourse_marker.wav</SoundFileName>
                <RandomizeInList>True</RandomizeInList>
            </PlayListItem>
            <PlayListItem>
                <Descr>PlayListItem 3</Descr>
                <SoundFileName>UIMusic\FSX08.wav</SoundFileName>
            </PlayListItem>
        </SimMission.PlayListAction>




        <SimMission.TimerTrigger InstanceId="{860011FB-F217-4FEF-BE94-C33C4F648AE9}">
            <Descr>_Triggered_TTimer_S60</Descr>
            <StopTime>60.000</StopTime>
 	    <Activated>False</Activated>
            <OnScreenTimer>True</OnScreenTimer>
            <Actions>
                <ObjectReference id="_Second_PLAYLIST_DIALOG_AD" InstanceId="{7808D1CE-FFDB-4727-A05E-093DB452DB0C}">
                </ObjectReference>
                <ObjectReference id="_Second_PLAYLIST_AP" InstanceId="{E768BFC8-F32E-450D-B095-C23F819AFD31}">
                </ObjectReference>
            </Actions>
        </SimMission.TimerTrigger>

        <SimMission.DialogAction InstanceId="{7808D1CE-FFDB-4727-A05E-093DB452DB0C}">
            <Descr>_Second_PLAYLIST_DIALOG_AD</Descr>
            <Text>
60 second Timer activated _Second_PLAYLIST_AP
</Text>
        </SimMission.DialogAction>

        <SimMission.PlayListAction InstanceId="{E768BFC8-F32E-450D-B095-C23F819AFD31}">
            <Descr>_Second_PLAYLIST_AP</Descr>
            <PlayListItem>
                <Descr>PlayListItem 1</Descr>
                <SoundFileName>thunder\xthun4c.wav</SoundFileName>
            </PlayListItem>
            <PlayListItem>
                <Descr>PlayListItem 2</Descr>
                <SoundFileName>lessons\atpding39.wav</SoundFileName>
            </PlayListItem>
            <PlayListItem>
                <Descr>PlayListItem 3</Descr>
                <SoundFileName>UIMusic\FSX03.wav</SoundFileName>
            </PlayListItem>
        </SimMission.PlayListAction>




:spushpin:
Thorsten -
This sort of stuff needs to go in the wiki.
Also a sticki to the wiki. :D

HTH
ATB
Paul
 
Last edited:
Snip: "Nobody wants to download 600MB of your favourite music."

The RIAA would beg to differ with you on this assertion. :D

Heh.

Thanks much for the update. This one vexed me (and a lot of others).
 
I also wonder if Paul could chime in here and tell us whether this is something that could be fixed in SP1.

My sense of this is that if everyone starts littering hard drives with mission files that need to exist outside of the mission folder, this could backfire on us very easily.

I haven't thought this through enough yet to make definitive statements, but that's my first sense of it.
 
Hi Folks

RNO -
I also wonder if Paul could chime in here and tell us whether this is something that could be fixed in SP1.

I don't know if anything is 'Broken'.
other than the info just being missing from the SDK.

Maybe Paul (P12C) could clarify.

My sense of this is that if everyone starts littering hard drives with mission files that need to exist outside of the mission folder, this could backfire on us very easily.

Hence my recommendation for the structured subfolder approach. :D
I've changed the recommended subfolder name,
as it would possibly confuse FS.

HTH
ATB
paul
 
Yea, I get that. Not saying it's broke so much as just the folder structure could lead to problems.

I like this structure for some reason:

\Missions
\MyDevelopedMission
\Sound
\Effects
\Music
\Scenery

This structure seems better to me (I'm open to discussion on this topic) as it let's me put everything that I developed into a subfolder I distribute. This let's me guarantee to the user I'm not overwriting files in their default install folders.

Somewhat along the same lines as MS creating a special folder for Add-On Scenery to give the user that same feeling that the Add-On stuff isn't overwriting their default installed files.

Just spitballing here and open to other thoughts. :o
 
Hi Folks

RNO -
Could you clarify please,
I can't tell if you're referring to subfolders of -
a) Microsoft Flight Simulator X\Sound
b) Microsoft Flight Simulator X\Missions\MyDevelopedMission\ add subfolders here.

i.e.
a) Just the naming of subfolders.
Or
b) A wishlist for MS to modify the way FSX playlists operate ATM.



Please include the subfolder paths,
starting -
Microsoft Flight Simulator X\



PS
'Missions' would be an inappropriate folder name,
you can guarantee someone will end up installing your playlist files
into the missions root folder -
Microsoft Flight Simulator X\Missions

If they misplace the file,
your mission will not run, at all. :redflag:



HTH
ATB
Paul
 
Thanks, Paul, for your very good work! :)

Why don'T you make an entry about this in the Wiki? Else I an see if I could do it over the weekend.
I really appreciate you found out how to use the playlist. :)
 
To clarify my earlier post:

I have qualms about adding files into folders OTHER THAN the mission folder I give to people which is placed into their

c:\program files\microsoft games\flight simulator x\missions

folder.

The game forces me to do that now. For example ... if I create an effect and distribute it with my mission, I have to place that .fx file into this folder (someone correct me if this is wrong):

c:\program files\microsoft games\flight simulator x\effects

This leaves open the opportunity that by doing this, I might overwrite an effect file that YOU placed there for YOUR mission that, coincidentally, we named the same. This would potentially break your mission.

If, instead, the mission folder that I create had its own set of subfolders for all the things I might develop for that mission, this potential wouldn't exist. Mission folders already have subfolders for dialogue ... the Sound subfolder. I'm thinking this could be expanded to include subfolders for

Effects
Scenery
Music

etc.

I think this would mean they have to change the game ... so, probably won't happen.

My thoughts anyway. Hope that clears it up.

(It occurs to me that I could be wrong in this assumption ... that in fact, I could place my .fx files in the mission folder and that it would work and prevent me from overwriting anything. I haven't tested this. Someone feel free to enlighten me if I have this bolluxed up.)
 
Last edited:
That is a new idea. Didn't think about that before. I'd like to try it - but I have to admit that I wasn't even able to use effects from the default folder. :o :D

See here - the gen_scenery_effect works fine, but attaching an fx to another object? Didn't work, whatever I did. :(
I'm sure you could teach me something in that, Kevin. :wave:
 
For example ... if I create an effect and distribute it with my mission, I have to place that .fx file into this folder (someone correct me if this is wrong):

c:\program files\microsoft games\flight simulator x\effects

This leaves open the opportunity that by doing this, I might overwrite an effect file that YOU placed there for YOUR mission that, coincidentally, we named the same. This would potentially break your mission.

Is it really that hard to give a unique name to effects file?
I mean, come on guys, this is not an issue unless you name your effects something like "fx_fire.fx". Use unique prefixes (you may use your name if you don't come up with anything clever) and everything's fine.
 
Hi Folks

RNO -
Thought that might be your intention. :)

It was the forum software which munged your post. :rolleyes:
The email notification included the data as you'd originally intended.

Recommend using the Indent button above,
rather than leading spaces, (which most forum software will automatically remove).

I agree generally with what you are saying,
however this has always been the case for any add-on file.

Recommend you name the file uniquely.
We're no longer limited to 8.3 filenames,
so it shouldn't be a problem.

Haven't tried placing effects into a child folder.



Thorsten -
Please see the 'effects attachpoint' original thread.



EDIT
Paavo beat me to it, LOL.

HTH
ATB
Paul
 
Back
Top