Jump to content
Sign in to follow this  
Bon

the UAV super AI

Recommended Posts

Hi all,

does anyone of you ever succeeded with getting the drone airborne (without creating it already flying of course)?

For me I always experience the following issue:

- UAV spawns at airfield,

- UAV gets Waypoints,

- UAV moves to runway,

- UAV speeds up,

- UAV lifts off, turning 90° to the left or right,

- UAV crashes into the trees.

No matter where the waypoints are, always the same story.

Ok, its a funny thing, but...

...how could I fix / work around it? Any suggestions / ideas?

Share this post


Link to post
Share on other sites

Is it getting into the air fast enough.? I was trying to use the northern airfield with some Russian jets and they just wouldn't get into the air in time and always splat into the nearby trees or mountains.

I ended up using this bit of code to workaround the problem:

   //--- Workaround to get aircraft to take off on bad runway.
   _vel = velocity RU_AIR_B;
   _dir = direction RU_AIR_B;
   _speed = 70; //--- Add speed
   RU_AIR_B setVelocity [(_vel select 0)+(sin _dir*_speed),(_vel select 1)+ (cos _dir*_speed),(_vel select 2)];

RU_AIR_B being the name of my jet.

Script your waypoints and apply this after you give the waypoint commands for take off. That will give an instant speed boost of 70 to get the UAV into the air quicker and hopefully it can get past those trees.

Also you might try making sure the waypoint is set to full speed and careless.

If you still have problems another thing which has been useful is to clear out the offending trees. Also use this in the init line for the UAV:

this flyInHeight 150

Share this post


Link to post
Share on other sites

No, told it to fly in height 900 or something, and it is also not the problem it doesn't have enough speed. It takes off after at most 75% of the runway.

It just takes off, turns to the left or right (independend of any waypoints I set) and ends up exploding in the trees.

Thought of setting the waypoint to careless and full speed might help, but it didn't.

My only idea is to detect when it touches off the ground and then add some speed to the z-value of its velocity.

But I am quite sure this would just result in unclean code ant that's not worth it.

Stupid AI. :681:

Share this post


Link to post
Share on other sites
My only idea is to detect when it touches off the ground and then add some speed to the z-value of its velocity.

Ya.. messy - but as with my jets maybe the only way for now. Try a trigger covering the end of the runway to add this speed. Not so bad that way.

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  

×