PDA

View Full Version : Stopping sound samples played by env_ambient?



awesomebillfromdawsonvile
13 Aug 2009, 10:01pm
Can anyone tell me why i cannot stop custom sounds in hammer?

I try to set up a button to play the song, and another button to turn it off, but for some reason the stop button never works for me.

I make sure to check "do not loop" for my env_ambient, but still i get the same problem. Ive tried giving it the stop command and the kill command, but neither work.

This problem happens most with sound that i import, but i notice that alot of samples that come with hl2 give me the same problem.

any help on this would be great =)

Olli3
15 Aug 2009, 02:10am
Do you mean ambient_generic? If not, try the Ambient_Generic..

Stevee
15 Aug 2009, 04:30am
Why not just have 1 button which puts the music on .
And when the music finishes it just stops.. much simpler then an on/off button/s.
And obviously dont make it loop.

awesomebillfromdawsonvile
15 Aug 2009, 12:51pm
yes i meant ambient generic. and its really important that i be able to stop the sample so that other samples can be played. ive already tried just letting the sample run out, and that way sux for me.

HankTheTank
15 Aug 2009, 01:40pm
Button One.

OnPressed
ambiant_Generic-Name
turnOn

Button two

OnPressed
Same Ambiant_Generic-Name
TurnOff

It makes no difference weather or not you have it set to loop.

awesomebillfromdawsonvile
16 Aug 2009, 12:07am
:thumb:

HankTheTank
16 Aug 2009, 07:17am
I'll take that as it worked?

awesomebillfromdawsonvile
16 Aug 2009, 03:07pm
its a thankyou for helpin, i havent tired yet though. I have a lot of other lil things to do on my map so thats a just one major problem checked off in my head.

Your answer was so different from anything ive tried, I just kinda assumed its gonna work.


edit:hammer shows that as a bad connection?

Bob Loblaw
16 Aug 2009, 07:55pm
It will be
Onpressed
Ambient Generic
Playsound

and

Onpressed
Ambient Generic
StopSound.