Home   Help Search Login Register  

Author Topic: Trigger Switch  (Read 2184 times)

0 Members and 1 Guest are viewing this topic.

Offline st3a1th

  • Members
  • *
Trigger Switch
« on: 08 Feb 2010, 20:05:53 »
Hello I am trying to get this trigger to switch units from waypoint0 to waypoint1 but can't seem to get it working. I checked the marker names and unit init and all is ok that side. I would like it to be set of by blufor and then switch the group to move. Can anyone help ?

_unit = _this select 0;
_group = group _unit;

_waypoint0 = _group addwaypoint[getmarkerpos"East_WP_1",0];
_waypoint0 setwaypointtype"Hold";
      

_trg0 = createTrigger["EmptyDetector",getmarkerpos"trig1"];
_trg0 setTriggerArea[50, 50, 0, false];
_trg0 setTriggerActivation["WEST","PRESENT",false];
_trg0 setTriggerType "SWITCH";
_trg0 setTriggerStatements ["this", "", ""];
_trg0 synchronizeTrigger [_waypoint0,_waypoint1];
_trg0 setTriggerText "Call for support";


_waypoint1 = _group addwaypoint[getmarkerpos"East_WP1_2",0];
_waypoint1 setwaypointtype"Move";

Thanks

Offline RangerX3X

  • Members
  • *
  • Ranger, out.
    • RangerX3X
Re: Trigger Switch
« Reply #1 on: 09 Feb 2010, 23:57:29 »
Waypoint 0 is where the group starts, with no waypoints. The first waypoint assigned to that group is waypoint 1.

_waypoint0 setwaypointtype"Hold"; should be _waypoint1 setwaypointtype"Hold";
Ranger, out.