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 Product Chat / How EXACTLY to attach a script to an entity?

Author
Message
Mugen Wizardry
User Banned
Posted: 30th Mar 2009 20:56
Hi, how EXACTLY do you attach a script to an entity, and activate the script? and don't tell me to use a trigger, b/c when i do, it doesn't show the correct thing.
knxrb
FPSC Tool Maker
16
Years of Service
User Offline
Joined: 10th Oct 2008
Location: United Kingdom
Posted: 30th Mar 2009 22:42 Edited at: 30th Mar 2009 22:47
To attach a script to an entity you place the entity, then right-click on it and you will get a list on the left of all the entity's properties.

Now look for the properties called 'Start', 'Main' and 'Destroy' in the 'AI Scripts' heading.

Now you need to decide when you want the script to be run; you can have it run when the entity is created(Start), when the entity is destroyed(Destroy) or have it running all the time(Main).

Click on the option you have chosen and a little button will appear to the right of the property.

Click the button and a browse window will open, select the script you want to set and then click 'OK'.

Theat script will now be set to run at the time you chose for that entity.

See attached picture for where the 'Ai Scripts' properties are and where the 'Browse' button is.

knxrb

Attachments

Login to view attachments
Mugen Wizardry
User Banned
Posted: 31st Mar 2009 02:31
how about to a window?
knxrb
FPSC Tool Maker
16
Years of Service
User Offline
Joined: 10th Oct 2008
Location: United Kingdom
Posted: 31st Mar 2009 12:27
Quote: "how about to a window? "

Umm, you've confused me, what do you mean 'how about to a window'?

knxrb

Mugen Wizardry
User Banned
Posted: 31st Mar 2009 16:17
how do u attach a script to a window? u know, a glass window?
Freakon
15
Years of Service
User Offline
Joined: 24th Feb 2009
Location:
Posted: 31st Mar 2009 18:20
What is it you would like the window to do?

Which script do you want to attach to the window?

And, you attach a script in the same way as knxrb described.

This is all covered in the user manual and the community giude.

Far too new to be helping...

knxrb
FPSC Tool Maker
16
Years of Service
User Offline
Joined: 10th Oct 2008
Location: United Kingdom
Posted: 31st Mar 2009 19:25
Quote: "how do u attach a script to a window? u know, a glass window? "

Oh right, when you said window I thought of a program window
Like spurs1al said, it works just the same as for other entities.

knxrb

Login to post a reply

Server time is: 2024-10-12 07:27:16
Your offset time is: 2024-10-12 07:27:16