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 zone help (repeats sound)

Author
Message
angusm3
15
Years of Service
User Offline
Joined: 6th Mar 2009
Location: Right behind you...
Posted: 24th Jul 2010 06:27
When i place a sound zone i want it to play the sound once and then never again
unfortunately when i walk over the sound zone twice it plays the sound twice
i just want the sound zone to go away after the sound is done playing
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 24th Jul 2010 11:49
Have it "destroy" once the player leaves the sound zone?


The one and only,


Marc Steene
FPSC Master
18
Years of Service
User Offline
Joined: 27th Mar 2006
Location: Bahrain
Posted: 24th Jul 2010 16:41 Edited at: 24th Jul 2010 16:41
Or just give it the script:

:state=0,plrwithinzone=1:sound=$0,state=1
:state=1:state=1


[b]FPSC MIGRATION: http://forum.thegamecreators.com/?m=forum_view&t=142497&b=21
Nbt
15
Years of Service
User Offline
Joined: 11th Oct 2009
Location: Behind you!!
Posted: 24th Jul 2010 18:13
I prefer to use the destroy method, as then there is no redundant looping script. Not really sure how much cpu cycles a looping script takes in FPSC though, but the less is maybe better

Bond1 - "I see this and think of a beach"
angusm3
15
Years of Service
User Offline
Joined: 6th Mar 2009
Location: Right behind you...
Posted: 24th Jul 2010 20:29
Quote: "Or just give it the script:

:state=0,plrwithinzone=1:sound=$0,state=1
:state=1:state=1"

so by doing that it will stay at state 1 which is after the state which plays the sound?

thanks guys
angusm3
15
Years of Service
User Offline
Joined: 6th Mar 2009
Location: Right behind you...
Posted: 24th Jul 2010 20:37
ok it was just the trigger zones
Mental note: don't use trigger zones for audio
and the script works

Login to post a reply

Server time is: 2024-11-24 21:33:29
Your offset time is: 2024-11-24 21:33:29