Jump to content

Get AI help to hover and then RTB?


Grifter

Recommended Posts

Hi,

 

I'm building a mission, but I'm having a lot of trouble getting the AI helicopter to do two things:

 

1.⁠hover for a certain period of time has elapsed OR a condition is met.

2.⁠Once that time has elapsed or the condition is met, I want it to switch to the next waypoint so it will RTB.

 

Can anyone tell me or direct me to instructions on how to set this up? I've messed with triggers, flags, time more, but I haven't figured out the right combination. I've placed the helo in orbit around the ship since I can't get it to hover. It's not ideal, but I would accept that if it would then transition to it's RTB waypoint after a trigger of some kind. But it refuses to do so. Any help here would be appreciated. Thanks.

 

 

Grifter-RLG

 

 

Sent from my iPhone using Tapatalk

Link to comment
Share on other sites

Couldn't you just have it orbit at 0knts then "stop condition" using a flag to identify that the intent of the hover has been met?

 

 

EDIT: Okay well I answered my own question and tested at least the orbit part.

 

Set the unit to orbit at 0. It takes it 30-40 seconds to settle in at around 0 but it looks like it'll hold there until it reaches the stop condition.

 

Set a small zone around the orbit location and set a flag for when the unit enters that zone. Then set a trigger to "time since flag" and set a second flag to when a certain time passes.

 

Then set your stop condition in your orbit to "user flag" and that it's checked off.

 

Of course you can use whatever other trigger to set a flag... then just refer to that flag when you want to "stop condition" the orbit.

 

 

That's probably not a glamorous way to do it but it should work.


Edited by ENO

"ENO"

Type in anger and you will make the greatest post you will ever regret.

 

"Sweetest's" Military Aviation Art

Link to comment
Share on other sites

Hey Eno,

 

 

Thanks for replying. I will give it a try. I've been messing with flags on and off under stop condition, and haven't been successful. Perhaps the speed at zero is the difference maker, I dunno. Hopefully it will work. Then, hopefully, I can switch waypoint once a certain condition is met. But, the thing is that the when I set the command to switch waypoint and fill out the necessary info, the line item in the window still lists a question mark. So I'm missing something or other. Anyway, I appreciate your suggestion and will give it a try.

Link to comment
Share on other sites

Got it to work! Thanks Eno!

 

 

 

In case anyone else is struggling with this, here is what I did:

 

 

 

1. Originally I only had two waypoints for this unit: 0 and 1. I decided to add an additional waypoint: 0, 1, and 2.

 

 

 

2. I set the chopper to spawn upon the part of the coalition entering zone, and that worked. Then at initial waypoint 0, I set it to racetrack orbit between 0 and 1.

 

 

 

3. Although it may not be necessary because it is already in a larger zone that triggered it's spawing, I set inside a smaller trigger zone dedicated to getting the chopper to hover.

 

 

 

4. When the unit enters (spawns) into this zone, I set flag #2, which is assigned to the chopper, to a value of 1.

 

 

 

5. I then created another trigger for time since flag set to 3 seconds; the resulting action of this trigger is to set flag #2's value to 0.

 

 

 

6. The stop condition for the chopper's orbit is set to flag #2 and is UNCHECKED.

 

 

 

The chopper doesn't even move. It spawns and stays hovering above the burning tanker perfectly!

 

 

 

Again, thanks to Eno for all the help.

Link to comment
Share on other sites

I get a perverse pleasure in seeing that what little I know can still help people achieve their goals. I have no doubt that a script could help you achieve it more elegantly... but for now I'm glad you got what you were after!

 

EDIT: Wait a sec... it looks like you started another thread... where are we at?

"ENO"

Type in anger and you will make the greatest post you will ever regret.

 

"Sweetest's" Military Aviation Art

Link to comment
Share on other sites

  • Recently Browsing   0 members

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