Vectors in FreeFlyer Script
-
- Posts: 4
- Joined: Mon Apr 15, 2024 4:17 pm
Vectors in FreeFlyer Script
The Vector and CoordinateSystem objects provide powerful and convenient methods for Vector analysis and manipulation. Vectors can be displayed in 2D and 3D visualizations and can be used to easily determine the range and direction to a specified target, calculate intersections with Proximity Zones or Vehicle 3D Models, or define custom coordinate systems. I recommend referencing our guide on Vectors and Coordinate Systems for more code snippets and examples. I also recommend referencing our guide on Viewing Objects for setting up visualizations.
Here is a simple code showing you how to build a vector in FreeFlyer Script and display the vector in a ViewWindow:
Here is a simple code showing you how to build a vector in FreeFlyer Script and display the vector in a ViewWindow:
Code: Select all
//Create Objects
Spacecraft Spacecraft1;
Vector SpacecraftToEarth;
ViewWindow ViewWindow1;
//Build Vector
SpacecraftToEarth.BuildVector(9, Spacecraft1, Earth);
//Configure ViewWindow
ViewWindow1.AddObject(Spacecraft1);
ViewWindow1.AddObject(SpacecraftToEarth);