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 / Switch that needs key and opens doors

Author
Message
Impaler
16
Years of Service
User Offline
Joined: 20th May 2008
Location: Everywhere...at the same time
Posted: 3rd Jul 2009 18:46 Edited at: 3rd Jul 2009 18:46
I'm practicing scripting by modding some of the scripts that came with fpsc. I want the switch to only work when the player has acquired a keycard. When the player has that key, use of the switch will open the door beside it. It looks like it should work but it doesn't. Here is what I have. Can anyone point me in the right direction?

Seth Black
FPSC Reloaded TGC Backer
19
Years of Service
User Offline
Joined: 22nd Feb 2005
Location: Pittsburgh, PA
Posted: 3rd Jul 2009 23:45
Quote: ";Artificial Intelligence Script

;Header

desc = Switch Activates Door When Key is Used. Door Stays Open

;Triggers

:state=0:hudreset,hudx=50,hudy=70,hudimagefine=gamecore\text\lockeddoor.tga,hudname=keydoorprompt,hudhide=1,hudmake=display,state=10
:plrdistwithin=50:hudshow=keydoorprompt,hudfadeout=keydoorprompt

:state=10,plrdistwithin=50,plrusingaction=1,plrhaskey=1:state=1,plrsound=$0,activateifused=1,alttexture=1


;End of Script"


...looks pretty good as is. Please note the slashes [\] that were missing from the posted version.

If you didn't already do so, alter the Switch's Properties:

IFUSED = [NAME OF DOOR HERE]



Login to post a reply

Server time is: 2024-11-25 03:26:38
Your offset time is: 2024-11-25 03:26:38