OFPEC Forum

Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting General => Topic started by: danturn on 06 Jul 2008, 20:24:44

Title: how do i get a named unit to set off a trigger? [solved]
Post by: danturn on 06 Jul 2008, 20:24:44
How can i set a trigger so that  a unit (named bob) sets it off and no one else?
Title: Re: how do i get a named unit to set off a trigger?
Post by: laggy on 06 Jul 2008, 20:54:23
Activation: anybody present
Condition: bob in thislist

Cheers
Laggy
Title: Re: how do i get a named unit to set off a trigger?
Post by: danturn on 06 Jul 2008, 21:36:53
excellent, thanks
Title: Re: how do i get a named unit to set off a trigger? [solved]
Post by: Cheetah on 06 Jul 2008, 23:48:11
Or, alternatively you could do it without any scripting commands, just by drawing a line as stated in the beginners tutorial (http://www.ofpec.com/tutorials/index.php?action=show&id=14&page=21).

Quote
This trigger won't be able to detect if the player is inside, because no activation has been filled in. We have two options, the first is to set activation to BLUFOR. It will then activate upon the player entering the trigger as he is on the BLUFOR side. However, to make the trigger more unique, we will synchronize the trigger and the player's unit. By doing that, the activation will switch to "vehicle" resulting in the trigger only activating upon the player's presence.

To do so, select F2 or groups and group the player and the trigger by drawing a line between them (Image 8). This should create a blue line between the trigger and the player's unit. If you open up the trigger's dialog, you will see that the activation has been switched to "vehicle". With this done, the mission should end upon completing both of the objectives and making it back to open sea - alive.

Note that however the method is different, the end result will be the same.