OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: gadolinite on 22 May 2003, 02:11:44
-
8)how would you play an alarm sound from a light post activated by a trigger? No, not the air raid siren, but the sound similar to a Ford Model A horn (Ahooo Ahooo) the one that never stops when activated by a trigger. However, if the light post is destroyed, I want the alarm to stop, simulating the effect of a speaker getting destroyed. It would be best to put this in a script?
How would you do this?
-
Place a trigger over the lamppost.
Actvation: repeatedly
Condition: alarm1
Effects: alarm sound
When the variable alarm1 is true, the alarm will sound. When it is false, it will not. Control the variable with scripts or triggers as you like. For instance you may have a trigger like this
Condition: (getdammage object 1234) > 0.9
On Activation: alarm1=false
syntax not guaranteed but you get the picture. Check your system of logic to ensure that the alarm will go on and off correctly even if the player does things in the wrong order.
-
:) :) :) :) :)thanks, Big mac :) :) :) :) :)
-
see 'deleting triggers' for an update