Home   Help Search Login Register  

Author Topic: Few questions about triggers...  (Read 1119 times)

0 Members and 1 Guest are viewing this topic.

Offline Krieg

  • Mission Maker
  • Members
  • *
  • Who dares wins.
Few questions about triggers...
« on: 10 Jul 2009, 19:32:03 »
Just a few questions about triggers...

1) Is following scenario possible: An aircraft enters a trigger, trigger informs player and he is given option to call airstrike via radio?
2) I know it is possible to "send" message to other units to attack following point on map via tirggers, but I wonder is it possible to determine their route via triggers (aka is unit going to attack via left or right route)?
If you see a light at the end of the tunnel, then it's probably an enemy tank.

Walter_E_Kurtz

  • Guest
Re: Few questions about triggers...
« Reply #1 on: 11 Jul 2009, 00:47:14 »
1. It takes more than just triggers; setRadioMsg command for starters.

Set up the airstrike trigger first: Radio Alpha, Once.

Then the aircraft's: place the trigger and then press 'Group (F2)'. Now click-and-hold to draw a line from the aircraft to the trigger. Next, edit the triggers properties: Vehicle, Present, Once. Then the important On Activation:
Code: [Select]
1 setRadioMsg "Call Airstike"; hint "Airstrike available"Now you need to create an init.sqs script file. This is called automatically once the mission starts - use it to hide the 'Airstrike' radio option until the trigger reveals it:
Code: (Init.sqs) [Select]
1 setRadioMsg "Null"

Variation: Multiple strikes
Make the triggers repeatable and use On Deactivation to reset. So, airstrike trigger: Radio Alpha, Repeatedly.

Aircraft: Vehicle, Present, Repeatedly
 - On Activation: 1 setRadioMsg "Call Airstike"; hint "Airstrike available"
 - On Deactivation: 1 setRadioMsg "Null"; hint "Cannot call airstrikes"


2.
I don't quite understand how you are ordering the units to attack - do you mean that you click on a point on the map, which they then attack?  I take it these are not units under your command?

Offline Krieg

  • Mission Maker
  • Members
  • *
  • Who dares wins.
Re: Few questions about triggers...
« Reply #2 on: 11 Jul 2009, 08:59:38 »
1. Thank you.
2. First give unit a hold waypoint then give it search and destroy waypoint, add a trigger (Radio Alpha, Once, Switch) and synchronize it with hold waypoint. Technique is similar to "charge" trigger for Russian troops you've "gave" me on "The Final Stand" mission. And yes, these are NOT units under your control.
That system is visible in "Stop SCUD from launching" mission in campaign of CWC.
« Last Edit: 11 Jul 2009, 11:17:23 by Krieg »
If you see a light at the end of the tunnel, then it's probably an enemy tank.

Walter_E_Kurtz

  • Guest
Re: Few questions about triggers...
« Reply #3 on: 11 Jul 2009, 16:24:05 »
It's a bit tricky to explain but you use the switch property of triggers to skip unnecessary waypoints.

Plot both routes for the unit in sequence - so a north route first then south, (see attached image).

The North trigger is to be synchronized with the first 'Hold' waypoint: Radio Alpha, Once, Switch, named "Go North"
 - On Activation: 2 setRadioMsg "Null"   <--- in order to hide option South, once North is chosen

The South trigger is to be synchronized with the final waypoint of route North: Radio Bravo, Once, Switch, named "Go South"
 - On Activation: 1 setRadioMsg "Null"


In the mission, when North is chosen, the units will make their way there and then stop - because they will not receive Radio Bravo.
When South is chosen, all the northern waypoints will be skipped and they will head south directly.


Advanced
Plot more waypoints after the objective and synchronize an Objective Trigger (Switch) with the final waypoint of route South. Then, after the objective is taken, they will resume a single course whether the southern or northern routes were taken.

Offline Krieg

  • Mission Maker
  • Members
  • *
  • Who dares wins.
Re: Few questions about triggers...
« Reply #4 on: 11 Jul 2009, 17:11:44 »
Thank you Walter, once again you've helped me. A lot.
If you see a light at the end of the tunnel, then it's probably an enemy tank.