OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting Multiplayer => Topic started by: stockholm on 08 Nov 2002, 14:07:40

Title: How does it work
Post by: stockholm on 08 Nov 2002, 14:07:40
I am having problems to make scripts to work.

1. i take a scrpit from the forum and cut it and paste it in
word and name the file test.sqs
 starts the game and nothing happens.

HELP HELP
Title: Re:How does it work
Post by: Diealot on 08 Nov 2002, 15:06:52
You have to use a trigger or a waypoint to exec the script.
Title: Re:How does it work
Post by: stockholm on 08 Nov 2002, 16:25:59
How do connect trigger with script ?
Title: Re:How does it work
Post by: Ranger on 08 Nov 2002, 19:59:07
I suggest that you check out the command reference:

http://www.flashpoint1985.com/docs/comref_102002/comref.html

This will give you a basis for using the various commands.

Now, to answer your question, follow these steps:

1. Create a trigger with whatever activation type that you wish.

2. In the trigger's activation field, input the following code:

[] exec "MyScript.sqs"

Obviously, replace MyScript with the name of your script.

3. Preview your mission.

That will do it.  There are plenty of other great tutorials on this site that you should check out for various editing information.  Just go to the Editors Depot to find them.
Title: Re:How does it work
Post by: stockholm on 12 Nov 2002, 17:24:42
i am allmost there , one more stupid q and refers to this

2. In the trigger's activation field, input the following code:
[] exec "MyScript.sqs"

? i dont get the above to work, because there is 3 ways to
put the line in the trigger i think
condition  "this"
on activation
deactivation

HOW do i make i file with the ending sqs i only have word and
wordpad.
Title: Re:How does it work
Post by: Ranger on 12 Nov 2002, 20:45:38
2. In the trigger's activation field, input the following code:
[] exec "MyScript.sqs"

? i dont get the above to work, because there is 3 ways to
put the line in the trigger i think
condition  "this"
on activation
deactivation

As my answer indicates, put it in the on activation field.

activation = on activation

These are the same thing, except that I just didn't type the "on" part.

Quote
HOW do i make i file with the ending sqs i only have word and
wordpad.

Save the file as Text Only with whatever name you want.  Then, go to the folder where you saved the file and rename the file from .txt to .sqs.