Jump to content
Sign in to follow this  
Matthijs

AI refuses to hover at 10m altitude (_this flyinhieght 10)

Recommended Posts

AI refuses to hover at lower altitudes between 5 and 60 meters. Everything below or above this bandwidth is quite ok.

Is there a workaround for this behaviour?  I would like to avoid setpos loops.

 

This works fine, for any altitude over 60, and SOMETIMES works for altitude 20:

 myHeli domove getpos player;
 myHeli flyinHeight 60;

The helicopter never responds to this, nor to and any other altitude between 10 and 20:

 myHeli domove getpos player;
 myHeli flyinHeight 10;
 
This works fine, for any altitude of 0 to 5:
 myHeli domove getpos player;
 myHeli flyinHeight 5;

Interestingly, the helicopter hovers at 5 meters altitude when I issue a flyInHeight between 5 and 10.

 
 
Is there any way to change this behaviour?

 

Share this post


Link to post
Share on other sites

Use this if you want your chopper to land. If you want for it to fly over sea at 5 meter altitude then that's probably impossible aside from manually setting position/velocity in a loop.

 

Edit: It usually doesn't work for me this simply and I have to spawn an invisible helipad and order the chopper to land at it for it to work.

Share this post


Link to post
Share on other sites

Use this if you want your chopper to land. If you want for it to fly over sea at 5 meter altitude then that's probably impossible aside from manually setting position/velocity in a loop.

 

I just want it to hover,

for fastroping  from a cargo helicopter

and for attack helicopters to take station in CAS missions.

 

 

Edit: It usually doesn't work for me this simply and I have to spawn an invisible helipad and order the chopper to land at it for it to work.

 

Ooh, that's a possible solution! I'm going to spawn an invisible helipad in mid-air.  B)

I'll let you know if this works. Thanks!!

 

 

 

Edit:

Yes, that worked!

 

Spawn an invisible helipad MYHELIPAD mid-air (e.g. 15 meters altitude), and then:

air1 domove getpos MYHELIPAD;
air1 land "LAND";

Now, the helicopter starts hovering at the altitude of the invisible helipad. Good enough for fastroping. Not good enough for attack helicopters on station though. I guess you can't have everything; too bad, because flyInHeight worked just fine in OFP.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×