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 / Basic question: Apply two scripts or create new one?

Author
Message
Leander
17
Years of Service
User Offline
Joined: 20th Sep 2007
Location: Austria
Posted: 4th Oct 2007 02:36
Can you also apply two or more scripts to an enemy?
e.g. he follows a waypoint and guards a door...when he sees you he runs to you, shoots at you...when you are out of sight again, he keeps guarding the door.

Can several scripts be applied to one character or do I need to create a new script, a new fpi with new name and insert the code for all actions I want the entity to have?

It's always so strange when I want a civilian to stay there...and he has the coward script. But when I shoot at him he should run for cover, run away, attack me...whatever. But not stand there and getting hit after hit.

[under construction]
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 4th Oct 2007 03:44
You cannot apply more than one script to a single entity. HOWEVER, you can do better than that.

You could go about this by creating one large script that does everything you want the guard to do.

Or you could combine many different scripts by telling each script at the end to "RUNFPI=[name of next script to run].fpi", where you will obviously replace that bracketed section with the name of the script you want to run. I don't recommend directly changing the default scripts in this manner, as every entity that uses them will be effected, you may want to just copy the default scripts and save them under your own name.


The one and only,
~PlystirE~

In Soviet Russia, road forks you!

Mom: I may not be the alpha and omega, but I can sure as hell be yours!

Login to post a reply

Server time is: 2024-11-23 22:38:27
Your offset time is: 2024-11-23 22:38:27