Howto:Implementing a simple GCA system: Difference between revisions

Jump to navigation Jump to search
Line 28: Line 28:


== Status ==
== Status ==
* implemented simple helper class to regularly fetch the corresponding aircraft properties and compute the delta between required heading/altitude and actual one
So far, we haven't actually coded up any heuristics at all: We merely ended up implementing the previously mentioned helper class to monitor/track an aircraft using a timer object, and call a single  buildInstruction() routine that internally deals with two geo.Coord() objects, one representing the destination (i.e. runway) and the other the permanently updated position of the aircraft that is being tracked.
 
We also looked up screen shots of actual ATC software to see what kind of parameters can commonly be configured for a GCA, which is why we put together a Canvas based UI dialog to more easily configure the GCA in FlightGear, including the corresponding offsets.
 
The whole thing is implemented in a fashion so that it can also be told to monitor AI/MP nodes, but also to be able to emit instructions using arbitrary output properties - which is to say that the script is capable of monitoring an AI/MP aircraft, and issuing instructions using the MP "chat" properties (just as well as the festival/flite TTS properties, or '''Spoken ATC''' itself).
 
In other words, once the heuristics are added, you could literally be running the GCA script on a multiplayer client to have it issue instructions to another MP client across the continent.
For the time being, there won't be any changes, but it's reached a state where it should be fairly straightforward to add custom heuristics, or even let it track/control AI nodes like tanker.nas<ref>{{cite web
  |url    =  https://forum.flightgear.org/viewtopic.php?p=316981#p316981
  |title  =  <nowiki> Re: Spoken ATC </nowiki>
  |author =  <nowiki> Hooray </nowiki>
  |date  =  Aug 20th, 2017
  |added  =  Aug 20th, 2017
  |script_version = 0.40
  }}</ref>


== Background ==
== Background ==

Navigation menu