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 / Decals On/Off, and decal sound question.

Author
Message
irdagam3r
16
Years of Service
User Offline
Joined: 8th Jun 2008
Location:
Posted: 10th Jun 2008 04:00
Hey guys,

I was wondering how exactly the script should look for, say, making a rain decal switch on/off periodically to make it look like rain is coming and going (and coming again).

I would like to mention that I have checked out the forums in addition to reading over the Hints N' Tips Guide by Nickydude. In that guide, I found a script that should work for my purpose (shown below).

;Artificial Intelligence Script
; 0-once face player
; 1-once keep angle
; 2-loop face player
; 3-loop keep angle
; 4-once face up
; 5-loop face up
; 6-character-spot-decal (at end of entity characters gun if available)

;Header
desc = Runs Decal Loop


;Triggers

:state=0,activated=1:state=1,rundecal=3
:state=1,activated=0:state=2,rundecal=-1

;End of Script

Something is obviously still wrong with the code because it doesn't produce the proper effect when applied to the AI Main on the rain decal. Help?

Another question...

Is it possible to make a sound associated with a decal

In this instance I would like the sound of rain to be looped whilst the player is around the ACTIVE rain decal.
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 10th Jun 2008 20:10
You'll want to use a 3d looping sound for the decal, which can be achieved with the "loopsound" command. Simply say "loopsound=<name of sound>", of course, with the proper path to go with it. The path starts from inside the "Files" folder, so if you're going to be using a sound inside the audiobank, let's say, in the "atmos" folder, it'll look like this:

loopsound=audiobank/atmos/sound.wav


As for your rain turning on and off, you have to activate the decal entity that the script belongs to. That'll need to be done in one of two ways.

1) Have another entity's script activate this entity
2) Have this script activate itself

If you want the script to activate itself, then you'll be usin the "activate=X" command, where X is the activatio value you want to be giving the script.

I'm not sure how you want to turn the decal on and off, but if it's with a timer, then you'll need to be aware that you only get a single timer with a non-Modded FPSC, and to get more, you'll need to go through some painstaking scripts using variables. (I believe Conjured Entertainment made one)


And there you have it. Go forth and create!!!


The one and only,


CoffeeGrunt
17
Years of Service
User Offline
Joined: 5th Oct 2007
Location: England
Posted: 12th Jun 2008 22:26
Ahh...never knew Loopsound used 2D calculation......

Great, now my Decal scripts'll stop being evil to me......

JunckMAn
16
Years of Service
User Offline
Joined: 23rd Apr 2008
Location: JunckLAnd
Posted: 13th Jun 2008 08:38
sorry, but about decals, is it possible to spawn decals by trigg zone

And u didnt believe i was russian

Login to post a reply

Server time is: 2024-11-24 09:33:27
Your offset time is: 2024-11-24 09:33:27