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 / Triggered lights

Author
Message
dumpus
16
Years of Service
User Offline
Joined: 1st Jan 2008
Location: Canada, eh?
Posted: 9th Apr 2009 05:26
Haven't had much luck with trying to script this, so I've come to you guys for help.

I'd like to have a dynamic light turn on when you open a door, and turn off when you close the door (and continue to do so each time it's opened and closed). Any help would be greatly appreciated.

Thanks!

Dar13
16
Years of Service
User Offline
Joined: 12th May 2008
Location: Microsoft VisualStudio 2010 Professional
Posted: 9th Apr 2009 22:15
what code do you have so far?

...
dumpus
16
Years of Service
User Offline
Joined: 1st Jan 2008
Location: Canada, eh?
Posted: 10th Apr 2009 01:40
I modified the dooruse script to activate the ifused property (in this case, "light1"), and gave "light1" the lightoff script. When I open the door, the light turns on, but when I close the door, the light doesn't turn off. Also, the light stays on for the remainder of the game, no matter how many times I open and close the door.

I'd also like to have the door close by itself when the player is a certain distance away from it...

dumpus
16
Years of Service
User Offline
Joined: 1st Jan 2008
Location: Canada, eh?
Posted: 11th Apr 2009 03:23
This is the doorused script:



I was experimenting, so there might be some useless stuff in there, I can't remember...

Right now, the script turns the light on when you open the door, but the light remains on no matter how many times you open/close the door.

Login to post a reply

Server time is: 2024-11-24 23:55:39
Your offset time is: 2024-11-24 23:55:39