CAG2 Posted June 30, 2017 Report Posted June 30, 2017 Hello everyone, I am making an application with the FSUIPC .NET client. I would like to make it so the aircraft can smoothly move from one point to another in a certain amount of time. I am coding in VB. Is this possible in FSUIPC? So far I've made it so the app records your coordinates when the form opens, then when you click a button it sends your aircraft back to that position. Public Class MainForm Dim lat As Offset(Of Long) = New Offset(Of Long)(&H560) Dim lng As Offset(Of Long) = New Offset(Of Long)(&H568) Dim latitude As Double Dim longitude As Double Private Sub MainForm_Load(sender As Object, e As EventArgs) Handles MyBase.Load FSUIPCConnection.Process() longitude = lng.Value latitude = lat.Value End Sub Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click lng.Value = longitude lat.Value = latitude FSUIPCConnection.Process() End Sub End Class Thanks in advance.
Paul Henty Posted July 4, 2017 Report Posted July 4, 2017 It's possible. You will need to experiment with putting the Sim in Pause or Slew mode. This will stop Flight Sim from updating the plane's position. You'll also have to work out the Lon/Lat positions along the path you want to move. Then, using some kind of timer loop, write each position along the path to 'animate' the plane. There are some helper classes in the DLL that can help with this. See the UserGuide.pdf and look at the FsLatLonPoint class. Especially the methods BearingTo, BearingFrom and OffsetBy... Paul
CAG2 Posted July 5, 2017 Author Report Posted July 5, 2017 Roger - will have a look when I have time. Thank you.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now