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 / Multiple effects in script - question

Author
Message
Leon Kennedy
16
Years of Service
User Offline
Joined: 7th Sep 2008
Location: Neither here nor there
Posted: 6th Oct 2008 22:33
I have one effect that needs to be seen immediately, but then I have an effect that I need to have triggered by a trigger zone. Here's what I need to accomplish:

1. Have a door start as open. I know that I'm supposed to alter something regarding the animations, but I'm not sure what exactly is supposed to be altered. I searched the forum, and I'm not sure I understand the answer. I'm a very detailed person, and I like lots of details.

2. Upon entering the trigger zone, the open door above needs to close.

Once the door closes, it needs to be only openable again once the player has the appropriate key. So I'm not sure with the door which of the following to do:

A. Use one door that is open and then closed, and then destroy that door and spawn a new door in the same place that only opens with a key; or
B. Use a door that opens only with a key for the whole thing.

I am guessing B, but I am not sure.

Anyhow, can someone help me out here? I'm not sure how to go about accomplishing the above, and I would really like to get this done. I think this would be a neat trick (the player leaves a room, sees the open door, takes a couple of steps and then watches the door close "by itself", only to realize that he needs a key to open the door again).

Anybody got any ideas on this?
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 7th Oct 2008 04:26
First things first... Have the door start in the open position.

You can accomplish this by opening one of the door scripts and seeing how the "opening" happens. Just have that happen right away in your script.

Now... have the script respond to being activated by a value that your triggerzone will give it. When the door is activated by the triggerzone, have it close.

Once it's closed, it will enter a new state (As well as a new activation value, so as not to constantly set the state that the activation value does), wherein the door will ask the player for a key.


What you're asking for is simple, it just a little bit of time to set up.


The one and only,


Those who live in the past, are destined to insanity. Those who live only for the future, will be slaves to their ambitions.
Those who live in the moment... only they, are truly happy.
Leon Kennedy
16
Years of Service
User Offline
Joined: 7th Sep 2008
Location: Neither here nor there
Posted: 8th Oct 2008 13:45
Yeah, I mentioned that I need to have the door start in the open position. I am just not sure how to accomplish doing that. Which file needs to be updated? I found a script out here that uses a trigger zone to close the door, so I'm good there. I just don't know how to get the door to start in the open position.
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 8th Oct 2008 21:08
Quote: "You can accomplish this by opening one of the door scripts and seeing how the "opening" happens. Just have that happen right away in your script."



I'm sorry, I can't do it for you. You need to learn this on your own.


The one and only,


Those who live in the past, are destined to insanity. Those who live only for the future, will be slaves to their ambitions.
Those who live in the moment... only they, are truly happy.
Leon Kennedy
16
Years of Service
User Offline
Joined: 7th Sep 2008
Location: Neither here nor there
Posted: 8th Oct 2008 22:30
Quote: "I'm sorry, I can't do it for you. You need to learn this on your own. "

Yeah. Right.

I'm told that I should search for the answer (or at least help on it) before posting. Which I did. The answer I got was to switch the animation frames. Which makes sense, but doesn't tell me which script to do it in. If I knew what script, I can figure it out.

Do I use the dooruse.fpi? Appear.fpi? Which script do I need to alter? I don't want to know which part of the script - only which script. That's the part I don't know. Don't want the answer - just want to be pointed in the right direction.
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 9th Oct 2008 00:00
Hmmmmmm....

To switch animation frames you'll want to open up the door's .fpe file inside it's entitybank directory.

As an example to help you out, the AutoDoor in the scifi section can be found in this location:

Files\entitybank\scifi\scenary\doors

They are all given similar names, but if you open up the .fpe files in Notepad there is a "desc =" near the top that will tell you which door it belongs to.

Find the FPE file of the door you are wanting to edit the animations for and in there you'll find near the bottom:

anim0 = 0,30

Or something like that.

These properties tell the door which animation frames to use for animations.

Changing them can be a bad idea if you don't know what you're doing, though.


I suggest just telling your script to setframe= for the "close" animation, which will set the door's animation to the beginning of it's close animation (which will be open). Do that at the beginning of your script and the door will appear to be open.


The one and only,


Those who live in the past, are destined to insanity. Those who live only for the future, will be slaves to their ambitions.
Those who live in the moment... only they, are truly happy.
Leon Kennedy
16
Years of Service
User Offline
Joined: 7th Sep 2008
Location: Neither here nor there
Posted: 9th Oct 2008 13:51
Thank you ply. That's what I needed - which file to edit. I'll actually make copies of the file for the door, and edit the copied files. That way I won't totally screw anything up, and I'll still have the original files.
Leon Kennedy
16
Years of Service
User Offline
Joined: 7th Sep 2008
Location: Neither here nor there
Posted: 15th Oct 2008 20:06
Quote: "anim0 = 0,30

Or something like that.

These properties tell the door which animation frames to use for animations.

Changing them can be a bad idea if you don't know what you're doing, though."

@Ply: Ok, so last night I downloaded one of the FPI Editors from out here (fantastic applications, aren't they?), and I tried playing around with the numbers above. And needless to say, I cannot get it to work.

The door is door_g_k.fpe (ww2 doors). I changed the above from 0,30 to 30,0. I did this thinking that if I switched the animations around (put them backwards), that the door animations would be done in reverse too. I didn't say the logic was good! Anyhow, it didn't work, so I changed them back.

Before I try my next move, I want to know if I am at least shooting in the right direction. I am going to try changing one, then both, to a 15, which would be halfway between 0 and 30. My thinking is that if 0 and 30 show the door closed, that 15 should (in theory) show the door open. Am I in the right ballpark here? Or do I need to play a different sport?

If I am not in the right ballpark, could you at least tell me where I could find out what animation frames are for the open door and which ones are for the closed door? This way, at least, I could determine which ones to use on my own - I would have only been shown where they were at.
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 16th Oct 2008 07:52
Start your script off with this:




That will cause the door to immediately get tot eh end of the animation. (The open frame)


The one and only,


Those who live in the past, are destined to insanity. Those who live only for the future, will be slaves to their ambitions.
Those who live in the moment... only they, are truly happy.

Login to post a reply

Server time is: 2024-11-24 14:06:16
Your offset time is: 2024-11-24 14:06:16