• There seems to be an uptick in Political comments in recent months. Those of us who are long time members of the site know that Political and Religious content has been banned for years. Nothing has changed. Please leave all political and religious comments out of the forums.

    If you recently joined the forums you were not presented with this restriction in the terms of service. This was due to a conversion error when we went from vBulletin to Xenforo. We have updated our terms of service to reflect these corrections.

    Please note any post refering to a politician will be considered political even if it is intended to be humor. Our experience is these topics have a way of dividing the forums and causing deep resentment among members. It is a poison to the community. We appreciate compliance with the rules.

    The Staff of SOH

  • Server side Maintenance is done. We still have an update to the forum software to run but that one will have to wait for a better time.

effects xml

mongoose

SOH-CM-2025
I'm adding a sound effect but seems to be an error which ChatGPY4o plus says is because 2 Effect5 with different effects?

<fx_engdebris_m____ ClassName="GroupEffect" Effect0="SmokeTrail_Air_XLRG_Brief" Effect1="SmokeTrail_Air_XLRG_Brief_w_delay" Effect2="AirDebris_S_Extended_SubGrp" Effect3="AirDebris_SML_SubGrp" Effect4="Air_Smoke_Flak1" Effect5="DebrisAir_dark_smoke"/>

<fx_engdebris_s ClassName="GroupEffect" Effect0="AirDebris_SML_SubGrp" Effect1="AirDebris_S_Extended_SubGrp" Effect2="snd_Expl_Air_S" Effect4="DebrisAir_dark_smoke" Effect5="DebrisAir_fireball_burst" Effect5="AirDebris_LRG_SubGrp" Effect6="Air_Smoke_Flak1"/>
 
It is right. Those are conflicting number sequences with conflicting effects. Try changing it to:

Effect6="AirDebris_LRG_SubGrp" Effect7="Air_Smoke_Flak1"/>

In my experience, within a "GroupEffect" the sequential effects should have sequential numbers but it never hurts to experiment to see what makes things tick. Did you use the effect as written in sim?
 
Last edited:
Yes, you can string quite a few effects together (starting with Effect0) including sound references. For example,

<fx_engfire_Ly ClassName="GroupEffect" Effect0="Air_Flames_solid_lrg_opt" Effect1="Air_fire_flame_Sparks_LRG_ADD2_opt" Effect2="Air_Flames_LRG_ADD1_opt" Effect3="Air_fire_L_Add_1" Effect4="snd_Expl_engfire_l" Effect5="Air_engfire_L_smoke" Effect6="G_Explosion_S_rising3x" Effect7="Air_fire_L_Add_1a" Effect8="DebrisAir_LRG1a_Small_constant3" Effect9="DebrisAir_LRG1_Small_constant3" Effect10="Air_fire_flame_Sparks_Trail_l" Effect11="Light_engfire_l" Effect12="Light_engfire_l2" Effect13="Light_engfire_l3"/>

The effects being grouped together can be either individual particle animation effects or other group collections of effects. Just be very careful to avoid any references in the subgroup effects that point back and forth at each other in an endless loop.
 
So this would be OK
<fx_engdebris_s ClassName="GroupEffect" Effect0="AirDebris_SML_SubGrp" Effect1="AirDebris_S_Extended_SubGrp" Effect2="snd_Expl_Air_S" Effect3="DebrisAir_dark_smoke" Effect4="DebrisAir_fireball_burst" Effect5="AirDebris_LRG_SubGrp" Effect6="Air_Smoke_Flak1"/>
since effect 3 was missing so to speak.

Full relevant lines would the be ( I assume this is Dan's work?)

<fx_engdebris_m____ ClassName="GroupEffect" Effect0="SmokeTrail_Air_XLRG_Brief" Effect1="SmokeTrail_Air_XLRG_Brief_w_delay" Effect2="AirDebris_S_Extended_SubGrp" Effect3="AirDebris_SML_SubGrp" Effect4="Air_Smoke_Flak1" Effect5="DebrisAir_dark_smoke"/>

<fx_engdebris_s ClassName="GroupEffect" Effect0="AirDebris_SML_SubGrp" Effect1="AirDebris_S_Extended_SubGrp" Effect2="snd_Expl_Air_S" Effect3="DebrisAir_dark_smoke" Effect4="DebrisAir_fireball_burst" Effect5="AirDebris_LRG_SubGrp" Effect6="Air_Smoke_Flak1"/>

<AirDebris_S_Extended_SubGrp ClassName="GroupEffect" Effect0="DebrisAir_delay1" Effect1="DebrisAir_delay2" Effect2="DebrisAir_LRG2_delay1" Effect3="DebrisAir_LRG4_delay3" Effect4="DebrisAir_ADD1_delay1" Effect5="DebrisAir_ADD1_delay1a" Effect6="DebrisAir_ADD1_delay1b" Effect7="DebrisAir_delay2a"/>
 
So does any effects expert know if this is acceptable in the effects file?


<Effect Type="NonVisual" Name="fx_Bake_Vor_beacon">
<Sound>
<SoundName>Bake_Vor</SoundName>
<Loop>TRUE</Loop>
<MinAttenuationDistance>5</MinAttenuationDistance>
<MaxAttenuationDistance>1500</MaxAttenuationDistance>
</Sound>
</Effect>
 
I sure am no expert in these matters, but I remember your type of information from the sounds.xml. My guess would be that you need to create an effect in the effects.xml first, which refers to your information in the sounds.xml, which in turn calls for the .wav file itself.

Take a look at how this sound effect from the stock CFS3 effects.xml is built up:

<snd_Expl_Land_L ClassName="SoundEffect" Sound="explosion/land/large" InitialDelay="0.0" MinDistance="1" MaxDistance="5000" Volume="100" Loop="0" OneShot="1"/>

It apparently refers to this entry in the sounds.xml:

<explosion Random="Yes" MinDistance="400" No3d="Yes" Looping="No" Static="Yes" Class="Explosion">
<land>
<large>
<sound file="amb_gexp5a.wav" />
<sound file="amb_gexp5b.wav" />
<sound file="amb_gexp5c.wav" />
</large>
</land>
</explosion>

Which, as you can see, refers to three .wav files that can be found in the CFS3 "sounds"-folder. Does that help?

BTW, there is a file around which explains what all the various attributes in the effects.xml file do (though it might refer to visual effects for the most part).
 
@mongoose - In regards to post #4: That looks OK to me. Did you test it in sim?

Post #5: From an aircraft XDP? I don't know. That looks a little too unconventional when compared to other effect line structures. I wouldn't think so but I'm no expert. Did you try it?

I usually try to find an existing comparable effect line/group and reverse engineer it until I get the desired effect. This is how I got my helo wash effect (not published yet) to work. Still working on trying to get it to show up at elevations above sea level.

If you're mixing non-stock effects it is a good idea to make sure the appropriate textures are present in the fxtextures folder and sound files in the sound folder. Double checking has always saved me a lot of aggravation.
 
Well in the end did

fx_Bake_Vor_beacon ClassName="SoundEffect" Sound="Bake_Vor" InitialDelay="0.0" MinDistance="5" MaxDistance="1500" Volume="100" Loop="1" OneShot="0"/>

However it didn't solve the problem of getting Morse code beacons to work. Looking at other ways around as I do have 3 simple Morse ones to work but not more complicated ones. Working on it!
 
I would agree with Foo; reverse engineer an existing effect.

How does your Morse code beacon work? Is it a gun that fires at the player's aircraft with no bullets/shells but with Morse code sounds instead of a gun sound effect? (I used that method to create the tail warning radar for the P-47). If so, I would start experimenting by copying and renaming a gun effect and replace its attributes with your files. If it is of a different design, choose another appropriate effect as a starting point...

And if you are trying to use a sound effect, I would still suggest the way I described the stock sound effect in my post #7 above. It would appear to me as if you are trying to call the .wav file directly from your fx file instead of through the sounds.xml. From your last post it is not clear to me what you got to work and what not.
 
I would agree with Foo; reverse engineer an existing effect.

How does your Morse code beacon work? Is it a gun that fires at the player's aircraft with no bullets/shells but with Morse code sounds instead of a gun sound effect? (I used that method to create the tail warning radar for the P-47). If so, I would start experimenting by copying and renaming a gun effect and replace its attributes with your files. If it is of a different design, choose another appropriate effect as a starting point...

And if you are trying to use a sound effect, I would still suggest the way I described the stock sound effect in my post #7 above. It would appear to me as if you are trying to call the .wav file directly from your fx file instead of through the sounds.xml. From your last post it is not clear to me what you got to work and what not.
OK so let's forget the effects.xml as that is not the issue as I am in fact calling up a wav file as you suggest so no need for it. The problem is CFS3 does not seem to like complicated Morse wav files. I have substituted a simpler wav file by swapping out one that is simple and putting it as the 'complicated' wav file name, which then works. I attache a 'simple' one that works, and an unchanged 'complicated' one that does not. So that seems to be the issue.
 

Attachments

  • wav files.zip
    1.1 MB · Views: 2
So, fx_Bake_Vor_beacon from post #8 works but the others don't? Are the others being used in this role as well, in this way with the same text structure? Try substituting fx_Bake_Vor_beacon within the text structure (while preserving the remaining text structure) with something that is not working and see what happens.

From your zip, Bake_AngrbodaBU is mono while knickebein_right is stereo. I don't know if this has a bearing on the intended application. Other sounds within CFS3 are stereo (especially the third party add-ons). A wav file is a wav file, after all.

A deeper look at text structures and comparing what works with what doesn't has helped me a great deal. The only thing I am an expert on is consuming pizza so consider my advice accordingly.
 
...
From your zip, Bake_AngrbodaBU is mono while knickebein_right is stereo. ...
...

(y) That's what I noticed too. See if a stereo file works. CFS3 can be quite picky when it comes to this type of things (formats, mono/stereo, sample rate etc.).

It should be quite easy to do with a program such as Audacity. If you need your sound only in the left or right channel, just move the balance slider or create an empty channel. You can still export it as a stereo .wav with sound audible only left or right to fulfill the possible stereo requirement.
 
Back
Top