OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: ahmed117 on 17 Dec 2011, 08:27:28

Title: Question about triggers...
Post by: ahmed117 on 17 Dec 2011, 08:27:28
This is Ahmed117 again,
                               sorry for another disturbance over here, but believe me I am really a junior editor, Okay the question is that, how to set a condition of a trigger? For Example: I want to activate a trigger when a specific unit or object enters in that range, Or activate when a specific unit is dead....so how to set this condition. Similarly, some missions I design take too much time to end, and if we die in the middle so we have to start again from the beginning, this is simply the wastage of time, I want the mission to "save position" and when ever we restart the mission we reach the same position the game had saved. Is there any command of trigger to do this? please answer me this last question, I assure you guys that I'll not ask any more questions.


Regards:
Ahmed Azher (A.rogers)
Title: Re: Question about triggers...
Post by: Gruntage on 17 Dec 2011, 09:31:35
In order for a trigger to be activated by a specific unit, you can do one of the following:

Group a trigger to the unit (the activation will change to 'vehicle present', instead of 'West/East/Resistance/Civilian Present')

OR

Put the following code in the condition field of a trigger:

Code: [Select]
person1 in thislist
For the second one you need to have 'West/East/Resistance/Civilian present' set.

Both of these methods have the same result so it doesn't matter which one you use.

The 'savegame' command is used when you need to choose a saving position for the player. This command can be used in both triggers and script.

Hope that answers your questions

Gruntage