Implementing VNAV support in FlightGear: Difference between revisions

Jump to navigation Jump to search
Line 514: Line 514:


The '''FGWaypoint''' class would need to be extended to help with the calculation of other types of waypoints related to VNAV. To add a stub for a new waypoint named '''waypoint_custom''', these would be the required changes (lacking any implementation in FGWaypoint::Run() ):
The '''FGWaypoint''' class would need to be extended to help with the calculation of other types of waypoints related to VNAV. To add a stub for a new waypoint named '''waypoint_custom''', these would be the required changes (lacking any implementation in FGWaypoint::Run() ):
* edit the src/models/flight_control/FGWaypoint.h header file add a new enum for your custom waypoint type
* edit the /src/models/flight_control/FGFCSComponent.cpp file to add a type mapping for the new waypoint
* edit src/models/FGFCS.cpp FGFCS::Load() to map the new waypoint to the FGWaypoint class
* implement the new functionality


<syntaxhighlight lang="diff">
<syntaxhighlight lang="diff">

Navigation menu