Jump to content

Help with triggers for simple mission

Recommended Posts

Greetings all,


I'm trying to make a simple air refueling mission.


When the tanker reach is last waypoint and start heading toward the first one, he does a 90 deg right turn, then a 180 deg left turn heading back to his flight path. So what i wanna do in MP, is when, he reaches 1 mile from his turning point, to send a message about his heading change in 1 mile, and when he starts to turn, sending the message he his changing his heading.


So what i've done is, creating a trigger zone of 2 miles, and put the center of it on his waypoint, then a smaller trigger zone for his turn.... Where i need help is, is it possible (since i don't know anything about flags..) that he only send the message of his 1 mile warning, when incoming only (i made the trigger (seitched condition, unit inside zone, send message to coalition) the thing is, when he does his 2 turns, he sorta reaches out of the zone and going back in, so he sends like total 3 times the message...


In othe words:


I want the tank to warn his incoming turn and heading change 1 mile in advance, then caling his turn and calling his final heading toward his flightpath.


We are learning formation refueling, so could be pretty much nice to be warn when he's about to reach his waypoint so we can pul back, make his pull back inside his boom.



Edited by Doum76
Link to comment
Share on other sites

Well, here's one way:


Switched("Tanker turn warning")->Conditions: {Unit inside zone (tanker, tanker zone) AND Flag is false(101)}-> Actions: {Set flag(101), Message to all("I wanna turn"), Sound to all (Iwannaturn.wav)}



Switched("reset 101")->Conditions: {Time Since Flag(101, 600)}-> Actions:{Clear Flag(101)}


With these two triggers, the tanker turn message can only be triggered at most, once every 600 seconds (10 minutes).


The flag, in this example 101, could be any integer number between 1 and, I donno... 10 million? 65535? I don't know what the limit is. The point is, make the number anyhting that makes sense to you, just don't make it excessively high. Certainly flags work up to 20000, I've used that one before.


Hope that helps.

Edited by Speed

Intelligent discourse can only begin with the honest admission of your own fallibility.

Member of the Virtual Tactical Air Group: http://vtacticalairgroup.com/

Lua scripts and mods:

MIssion Scripting Tools (Mist): http://forums.eagle.ru/showthread.php?t=98616

Slmod version 7.0 for DCS: World: http://forums.eagle.ru/showthread.php?t=80979

Now includes remote server administration tools for kicking, banning, loading missions, etc.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...