Status of AI in FlightGear: Difference between revisions

Jump to navigation Jump to search
Line 104: Line 104:


{{FGCquote
{{FGCquote
   |he simplest solution is probably using scripted AI traffic nodes. Note however that AI traffic cannot currently make use of any FDMs (JSBSim/YaSim), instead you need to come up with your own "pseudo FDM" in scripting space.<br/>
   |The simplest solution is probably using scripted AI traffic nodes. Note however that AI traffic cannot currently make use of any FDMs (JSBSim/YaSim), instead you need to come up with your own "pseudo FDM" in scripting space.<br/>
<br/>
<br/>
You might be able to circumvent this restriction by coming up with a separate FDM and communicating with FG using sockets.<br/>
You might be able to circumvent this restriction by coming up with a separate FDM and communicating with FG using sockets.<br/>
Line 120: Line 120:
     |author=<nowiki>Hooray</nowiki>
     |author=<nowiki>Hooray</nowiki>
     |date=<nowiki>Tue Jan 03</nowiki>
     |date=<nowiki>Tue Jan 03</nowiki>
  }}
}}
{{FGCquote
  |It really doesn't take any longer than say 2-3 minutes to open the tanker.nas script, change the model file name to point to the 3D model of a bird, what you end up with is a "funny bird" flying at 330+ kts ground speed at 17000 ft AMSL (I took the first freely available bird model that I could find...):<br/>
<br/>
(see the [http://img830.imageshack.us/img830/7319/birdstrike.png linked image])<br/>
<br/>
As a next step, one could change the heuristics that move the bird (assuming that you don't want it to keep flying refueling patterns...), making it search actual thermals (local weather) would also not seem too complicated - it would just involve calls into the local weather code. <br/>
<br/>
Probably, you'll want to add some collision detection code then.<br/>
Once this is working, you may want to animate the whole thing and probably change its size, too.<br/>
<br/>
Like I said, it's all perfectly possible with the tanker.nas script.
  |{{cite web |url=http://forum.flightgear.org/viewtopic.php?p=96233&sid=5664929fd1b8b8832383a6240f882ba9#p96233
    |title=<nowiki>Re: Bird strikes script</nowiki>
    |author=<nowiki>Hooray</nowiki>
    |date=<nowiki>Wed Sep 22</nowiki>
   }}
   }}
}}
}}

Navigation menu