Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

FPSC Classic Scripts / Sound in zone

Author
Message
Nickydude
Retired Moderator
18
Years of Service
User Offline
Joined: 4th Nov 2006
Location: Look outside...
Posted: 12th Jan 2007 00:37 Edited at: 12th Jan 2007 01:04
Please move to the Scripts, I've put this in the wrong place

I'm tearing my hear out trying to get this to work. I want a sound playing while the player is in a zone then stop when the player leaves the zone.

I've tried it with a sound zone and a trigger zone, I've tried it with the soundinzone.fpi and musicinzone.fpi. I can get the sound to play ok when the player enters the zone but it just will not stop when the player leaves (it stops naturally when it reaches the end of the sound, which is 1 min long).

I just want the sound (.ogg) to stop as soon as the player leaves the zone! Can anyone shed any light?

Edit: Ok, I think I've now sorted it.?


Nickydude
Retired Moderator
18
Years of Service
User Offline
Joined: 4th Nov 2006
Location: Look outside...
Posted: 12th Jan 2007 01:04 Edited at: 12th Jan 2007 02:21
I though I might have sussed it. I have the following script:



Which doesn't seem to work. Does "sound=$0" mean "play the sound specified in 'sound0'"?

Can anyone help me stop a sound?


FredP
Retired Moderator
18
Years of Service
User Offline
Joined: 27th Feb 2006
Location: Indiana
Posted: 12th Jan 2007 02:22
Moving to the scripts forum.

Login to post a reply

Server time is: 2024-11-23 08:57:40
Your offset time is: 2024-11-23 08:57:40