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 / Dynamic Ambience Script

Author
Message
Hamburger
15
Years of Service
User Offline
Joined: 23rd Jun 2009
Location: Grand Rapids MI
Posted: 9th Mar 2013 15:38
Hello all, just venturing into the forays of scripting again...

I was just wondering if anybody who is good with scripts could look at my script here and see if it would work correctly...

Basically what I have here is a script that will play a random sound, at a random time interval, with a random camera shake magnitude. I also put some plrwobble in it for overall realism.

The script is applied to a trigger zone way off the map.

I got the idea playing rage, every once in a while the camera shakes lightly and a sound (like metal creaking or earthquakes) would play.

(Replace X with sound files and associated paths)

Here is the script:



[/href]

BACK FPSC:R! http://kck.st/Tmi93T
BlackFox
FPSC Master
16
Years of Service
User Offline
Joined: 5th May 2008
Location: Knight to Queens Bishop 3
Posted: 9th Mar 2013 15:44 Edited at: 9th Mar 2013 15:48
Replace the "timerstart/timergreater" with "etimerstart/etimergreater". The reason is this- if you have another script using "timerstart/timergreater", they will conflict and not run properly. It is always good to use the "etimer" as you can have multiple run at the same time.

Also, your syntax is slightly off- you have commas in place of colons.




There's no problem that can't be solved without applying a little scripting.
Hamburger
15
Years of Service
User Offline
Joined: 23rd Jun 2009
Location: Grand Rapids MI
Posted: 9th Mar 2013 15:54
Hmm thanks Blackfox, forgot about the etimer... also thanks for correcting my syntax as well!

[/href]

BACK FPSC:R! http://kck.st/Tmi93T
Hamburger
15
Years of Service
User Offline
Joined: 23rd Jun 2009
Location: Grand Rapids MI
Posted: 9th Mar 2013 21:32
Errrgh, just tested this script and the sounds didnt play. The player wobble works, but I think maybe I got some conditions and actions switched up somewhere... Any thoughts? I cant seem to find out the problem...

[/href]

BACK FPSC:R! http://kck.st/Tmi93T
Corno_1
14
Years of Service
User Offline
Joined: 3rd Nov 2010
Location:
Posted: 10th Mar 2013 08:54
sometimes:


Check this ....


Hamburger
15
Years of Service
User Offline
Joined: 23rd Jun 2009
Location: Grand Rapids MI
Posted: 10th Mar 2013 14:06
Thanks Corno I'll try that in a jiff! You guys are great when it comes to scripting things.

[/href]

BACK FPSC:R! http://kck.st/Tmi93T

Login to post a reply

Server time is: 2024-11-23 16:59:32
Your offset time is: 2024-11-23 16:59:32