Skip to main content
deleted 35 characters in body
Source Link
Yos233
  • 186
  • 3

If I were you, I would use a simple algorithm to point the aircraft at the target. You can use a turnrate variable to keep track of how quickly it is turning. This is something I am using in my project.

Within the update method, calculate the projected heading a few seconds in the future. If the projected heading has not passed the target heading, increase the turn rate (up to a maximum). If the projected heading is beyond the target heading, reduce the turn rate.


The reason I highly suggest you do this is because the mathematics for constructing and following a curve between two points is very complicated. It has to be to handle all of the special cases that you might encounter. Like, what happens when your target is much further east than north, but your plane is heading north? You couldn't construct a circle between the points because the initial angle would be very close to eastin a way that works.

If you would like me to go into further detail in a second answer I will, but only at the abstract level. I have no idea how you would implement it in your program.

If I were you, I would use a simple algorithm to point the aircraft at the target. You can use a turnrate variable to keep track of how quickly it is turning. This is something I am using in my project.

Within the update method, calculate the projected heading a few seconds in the future. If the projected heading has not passed the target heading, increase the turn rate (up to a maximum). If the projected heading is beyond the target heading, reduce the turn rate.


The reason I highly suggest you do this is because the mathematics for constructing and following a curve between two points is very complicated. It has to be to handle all of the special cases that you might encounter. Like, what happens when your target is much further east than north, but your plane is heading north? You couldn't construct a circle between the points because the initial angle would be very close to east.

If you would like me to go into further detail in a second answer I will, but only at the abstract level. I have no idea how you would implement it in your program.

If I were you, I would use a simple algorithm to point the aircraft at the target. You can use a turnrate variable to keep track of how quickly it is turning. This is something I am using in my project.

Within the update method, calculate the projected heading a few seconds in the future. If the projected heading has not passed the target heading, increase the turn rate (up to a maximum). If the projected heading is beyond the target heading, reduce the turn rate.


The reason I highly suggest you do this is because the mathematics for constructing and following a curve between two points is very complicated. It has to be to handle all of the special cases that you might encounter. Like, what happens when your target is much further east than north, but your plane is heading north? You couldn't construct a circle between the points in a way that works.

If you would like me to go into further detail in a second answer I will, but only at the abstract level. I have no idea how you would implement it in your program.

Source Link
Yos233
  • 186
  • 3

If I were you, I would use a simple algorithm to point the aircraft at the target. You can use a turnrate variable to keep track of how quickly it is turning. This is something I am using in my project.

Within the update method, calculate the projected heading a few seconds in the future. If the projected heading has not passed the target heading, increase the turn rate (up to a maximum). If the projected heading is beyond the target heading, reduce the turn rate.


The reason I highly suggest you do this is because the mathematics for constructing and following a curve between two points is very complicated. It has to be to handle all of the special cases that you might encounter. Like, what happens when your target is much further east than north, but your plane is heading north? You couldn't construct a circle between the points because the initial angle would be very close to east.

If you would like me to go into further detail in a second answer I will, but only at the abstract level. I have no idea how you would implement it in your program.