skacky on 30/7/2013 at 18:59
Hey y'all.
I've been trying to setup something really simple, but despite my efforts it doesn't work. I'm sorry if the issue sounds really simple but I'm a bit tired today. :p
I have an object in my mission and there is an AmbientHacked marker next to it so it sounds like the sound is coming from the object. The AmbientHacked uses a looping sound with a NoSharpCurve prop on it. When the player frobs the object and puts it in their inventory, I want the sound to stop. I used a StdButton script on the object with a CD link to a DestroyTrap with the DestroyTrap CD linked to the marker, but the sound is still playing when I get the object. My FrobInfo properties for the object are set to World Action: Move, Script.
So, my question is: am I doing this wrong or can't a looping sound be destroyed?
Ricebug on 30/7/2013 at 19:36
You can add the AmbientHacked prop to the object itself. Torches use it.
Yandros on 30/7/2013 at 21:55
That should do it, but if not change the StdButton script to TrigContained on your current setup and it will probably work. If the DestroyTrap doesn't do the trick, then replace it with an inverter to send TurnOff to the sound trap.
MysteryMan on 30/7/2013 at 21:57
Yes, placing the ambient hacked loop on the object going into inventory is a good thing.
Otherwise, this will work.
1.On the ambient hacked marker add S>Scripts>ActivateAmbient, in the ambient hacked flags, use TurnedOff.
2.Use a concrete roombrush with TrigRoomPlayer>cd linked>relaytrap>cd linked to the ambient hacked marker,then cd link the relaytrap to the destroytrap, then the destroy trap to the relaytrap. This way the roombrush will only fire once.
3.On your object going into inventory use frob info:
World Action :Move
Inv Action:Script
Add S>Scripts:TrigContained
Cd Link the object going into inventory to an inverter, then cd link the inverter to the marker.
Here is how it works:
The roombrush sends a TurnOn to the ambient hacked marker, then when the object goes into inventory the
ActivateAmbient receives a TurnOff via the Inverter.
skacky on 30/7/2013 at 22:21
I've tried both your solutions, Yandros and MysteryMan, but none of them work. Either I don't do them correctly or something's wrong with my dromed. When I try MysteryMan's the sound never plays.
MysteryMan on 30/7/2013 at 22:31
Quote Posted by skacky
I've tried both your solutions, Yandros and MysteryMan, but none of them work. Either I don't do them correctly or something's wrong with my dromed. When I try MysteryMan's the sound never plays.
I have a little demo I can send you, if you would like. Either just the object, or the combination of the object and the ambient hacked marker.
skacky on 30/7/2013 at 22:34
You can send me both if you like, I'll pick the one I prefer. :p
Xorak on 30/7/2013 at 23:10
I'd put an AmbientHacked property on the object, with a custom TouchStim on the object.
When Garrett frobs the object, it stims the stim, flicks a switch and turns the ambient off. I think I used that setup numerous times in my last mission.
skacky on 31/7/2013 at 12:51
Thanks MysteryMan, this works. :D