Table of Contents

Class ManeuverPlanSolver

Namespace
KSP.Sim.impl
Assembly
Assembly-CSharp.dll
public class ManeuverPlanSolver : IDisposable
Inheritance
ManeuverPlanSolver
Implements
Inherited Members
Extension Methods

Constructors

ManeuverPlanSolver(UniverseModel, OrbiterComponent)

Creates a ManeuverPlanSolver using the supplied UniverseModel for the supplied OrbiterComponent.

public ManeuverPlanSolver(UniverseModel universeModel, OrbiterComponent orbiter)

Parameters

universeModel UniverseModel
orbiter OrbiterComponent

Fields

MAX_PATCHEDNBODY_SOLVES

Max value = 10

public const int MAX_PATCHEDNBODY_SOLVES = 10

Field Value

int

Properties

HasActiveManeuver

A flag indicating if this maneuver plan has an active maneuver.

public bool HasActiveManeuver { get; }

Property Value

bool

ManeuverTrajectory

List of maneuver trajecotries.

public List<IPatchedOrbit> ManeuverTrajectory { get; }

Property Value

List<IPatchedOrbit>

PatchedConicsList

List of patched conic orbits.

public List<PatchedConicsOrbit> PatchedConicsList { get; }

Property Value

List<PatchedConicsOrbit>

PatchedNBodyList

List of Patched N-Body Orbits.

public List<PatchedNBodyOrbit> PatchedNBodyList { get; }

Property Value

List<PatchedNBodyOrbit>

TargetBody

The target celestial body.

public CelestialBodyComponent TargetBody { get; }

Property Value

CelestialBodyComponent

Methods

Dispose()

Good question!

public void Dispose()

FindPatchContainingUt(double, List<IPatchedOrbit>, out IPatchedOrbit, out int)

public void FindPatchContainingUt(double ut, List<IPatchedOrbit> patchList, out IPatchedOrbit patch, out int patchIndex)

Parameters

ut double
patchList List<IPatchedOrbit>
patch IPatchedOrbit
patchIndex int

FindPatchContainingUt(double, List<PatchedConicsOrbit>, out IPatchedOrbit, out int)

public void FindPatchContainingUt(double ut, List<PatchedConicsOrbit> patchList, out IPatchedOrbit patch, out int patchIndex)

Parameters

ut double
patchList List<PatchedConicsOrbit>
patch IPatchedOrbit
patchIndex int

GetVelocityAfterFirstManeuver(out double)

public Vector GetVelocityAfterFirstManeuver(out double UT)

Parameters

UT double

Returns

Vector

HandleNodeAdded(List<ManeuverNodeData>, ManeuverNodeData)

public void HandleNodeAdded(List<ManeuverNodeData> nodes, ManeuverNodeData nodeAdded)

Parameters

nodes List<ManeuverNodeData>
nodeAdded ManeuverNodeData

HandleNodeBurnChanged(List<ManeuverNodeData>, ManeuverNodeData)

public void HandleNodeBurnChanged(List<ManeuverNodeData> nodes, ManeuverNodeData nodeChanged)

Parameters

nodes List<ManeuverNodeData>
nodeChanged ManeuverNodeData

HandleNodePositionChanged(List<ManeuverNodeData>, ManeuverNodeData)

public void HandleNodePositionChanged(List<ManeuverNodeData> nodes, ManeuverNodeData nodeChanged)

Parameters

nodes List<ManeuverNodeData>
nodeChanged ManeuverNodeData

HandleNodesRemoved(List<ManeuverNodeData>, List<ManeuverNodeData>)

public void HandleNodesRemoved(List<ManeuverNodeData> currentNodes, List<ManeuverNodeData> removedNodes)

Parameters

currentNodes List<ManeuverNodeData>
removedNodes List<ManeuverNodeData>

OnStart()

Mono behavior called automatically.

public void OnStart()

OnUpdate()

Mono behavior called automatically.

public void OnUpdate()

SetPatchesInactive(List<PatchedNBodyOrbit>, int)

public static void SetPatchesInactive(List<PatchedNBodyOrbit> patchedNBodyOrbits, int startIndex = 0)

Parameters

patchedNBodyOrbits List<PatchedNBodyOrbit>
startIndex int

SetTarget(CelestialBodyComponent)

Set the TargetBody pameter using the supplied CelestialBodyComponent.

public void SetTarget(CelestialBodyComponent targetBody)

Parameters

targetBody CelestialBodyComponent

UpdateManeuverTrajectory()

Updates all the PatchedConicsOrbit list for this maneuver plan?

public void UpdateManeuverTrajectory()

UpdatePositionVelocityForSoiCross(IPatchedOrbit, PatchedNBodyOrbit, double, ref Vector3d, ref Vector3d)

Updates the position and velocity vectors for the SOI transition using the supplier patch and patchedNBodyOrbit.

public static void UpdatePositionVelocityForSoiCross(IPatchedOrbit patch, PatchedNBodyOrbit patchedNBodyOrbit, double subStageStartUt, ref Vector3d localPosition, ref Vector3d localVelocity)

Parameters

patch IPatchedOrbit
patchedNBodyOrbit PatchedNBodyOrbit
subStageStartUt double
localPosition Vector3d
localVelocity Vector3d