Jump to content

Play a File When a Target is destroyed. Need a Hint


Recommended Posts

Posted (edited)

Guys, I've been trying to set up this thing in my mission and I have managed to get it work, but it works only first time (it does not work after unit respawned), and sometimes it does not work at all.

I need it to play a file when a target is destroyed, even after it had respawned and then destroyed again. Do you know how to do it properly?

I think that it could be because of the ON CRASH trigger that I use, which probably works only once, and after the unit respawned, the trigger does not work anymore?

I'm using slmod. Maybe it can help?

 

Thank you. :smilewink:

The solution: use 3 SWITCHED ACTION + FLAGs

The problem was: ON CRASH + UNIT IN ZONE.

Edited by H-var

2. The DCS MOVIE information!

4. REAL UFO FOOTAGE

I don't trust anything that bleeds for five days, and doesn't die

 

government: gives me money because of coronavirus

me: spends all money on the missing DCS modules

government: ... you dumbo! We won't give you money anymore

me: It's ok. I don't need anything else - I now have the entire DCS collection

my cat: looking at the empty bowl for a while and goes back to sleep

me: it's hard times, Mig, suck it up!

 

[sIGPIC][/sIGPIC]

Posted
Use a switched condition. Just flip the flag off right under where you play the sound.

 

like paganus told, why you did not using flags?:

 

type:

 

  • 2continuous action or 3switched condition

conditions:

 

  • flag is true (#)

actions:

 

  • group snd or sound to (soundfile)

 

  • flag off (#)

Posted

Hmm.. looks like you have all the actions in the trigger? The way it is setup now it will do all of the actions you have once the condition is met.

 

So yes it will play to all groups because you have defined an action to play a sound for every group that will fire in sequence once the trigger condition is true.

I7920/12GBDDR3/ASUS P6T DELUXE V2/MSI GTX 960 GAMING 4G /WIN 10 Ultimate/TM HOTAS WARTHOG

Posted

try this here:

first - set a flag for the dead unit (flag number is depending on the number of flags in your mission)

second - if flag is true => sound

you need the flag off for a end of playin the soundfile

 

type:

 

  • 1 once

conditions:

 

  • unit or group dead

actions:

 

  • flag on (1234)

 

type:

 

  • 2continuous action or 3switched condition

conditions:

 

  • flag is true (1234)

actions:

 

  • group snd or sound to (soundfile)

 

  • flag off (1234)

Posted
try this here:

first - set a flag for the dead unit (flag number is depending on the number of flags in your mission)

second - if flag is true => sound

you need the flag off for a end of playin the soundfile

 

 

did you check both in once? i did not meant try this and/or that

=> both (first AND second) must be in one mission

Posted
Yes, Eagle, I have added both triggers.

 

was just a guess....

 

i will add some file, but you have to wait till tomorrow...iam not at my pc at now...

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...