Patch#

public class Patch#

A patch of the trajectory, at its position in Trajectories.patches().

Note

Trajectories computes the trajectory again as the vessel flies, and the patch reads the latest one. Throws an exception if the trajectory has fewer patches.

org.javatuples.Triplet<Double, Double, Double> position(SpaceCenter.ReferenceFrame referenceFrame)#

The position of the impact, or null without one.

Parameters:
Game Scenes:

Flight

Note

In a reference frame that rotates with Patch.getBody(), the position includes the rotation of the body until the impact.

org.javatuples.Triplet<Double, Double, Double> velocity(SpaceCenter.ReferenceFrame referenceFrame)#

The velocity at the impact, or null without one.

Parameters:
Game Scenes:

Flight

Note

In a reference frame that rotates with Patch.getBody(), the velocity includes the rotation of the body until the impact.

SpaceCenter.CelestialBody getBody()#

The celestial body that the patch is relative to.

Game Scenes:

Flight

double getStartUT()#

The universal time at the start of the patch, in seconds.

Game Scenes:

Flight

double getEndUT()#

The universal time at the end of the patch, in seconds.

Game Scenes:

Flight

Note

For a patch that ends in an impact, this is the time of the impact.

boolean getAtmospheric()#

Whether the patch is inside an atmosphere.

Game Scenes:

Flight

java.util.List<org.javatuples.Quartet<Double, Double, Double, Double>> atmosphericTrajectory(SpaceCenter.ReferenceFrame referenceFrame)#

The points of an atmospheric patch, or null for a patch in space.

Parameters:
Game Scenes:

Flight

Note

Each point is a tuple (ut, x, y, z). In a reference frame that rotates with Patch.getBody(), the positions include the rotation of the body until each point.

SpaceCenter.Orbit getOrbitalTrajectory()#

The orbit of a patch in space, or null for an atmospheric patch.

Game Scenes:

Flight